lsflib/src/get_line.c
changeset 29 7abf6146898e
parent 9 c3fecc82ade6
child 77 49e0babccb23
equal deleted inserted replaced
28:54addf5893ef 29:7abf6146898e
    15 
    15 
    16 char *get_line (const char *filename, const char *cmd, size_t size)
    16 char *get_line (const char *filename, const char *cmd, size_t size)
    17 {
    17 {
    18     int i, j;
    18     int i, j;
    19     char *line, *ptr;
    19     char *line, *ptr;
       
    20 
    20     FILE *f = fopen (filename, "r");
    21     FILE *f = fopen (filename, "r");
    21 
    22 
    22     if (!f) {
    23     if (!f) {
    23         perror ("FOPEN:");
    24         perror ("FOPEN:");
    24         return NULL;
    25         return NULL;