All pastes #247142 Raw Edit

Stuff

public c v1 · immutable
#247142 ·published 2006-11-13 02:14 UTC
rendered paste body
#include "bsq.h"int     bsq(char *fichier){  char  *str;  int   fd;  int   longueur;  int   fdread;  int   tmp;    longueur = 0;  str = (char *)malloc(sizeof(str) * get_lenght(fichier));  if ((fd = open(fichier, O_RDONLY, 0)) == -1)    aff_err("open");  if ((tmp = lseek(fd, 2, SEEK_SET) == -1)    aff_err("lseek");  if ((fdread = read(fd, str, get_lenght(fichier))) == -1)    aff_err("read");  while (str[longueur++] != '\n')  find_sq(str, longueur);  return (0);}