add check for symlinks
Este commit está contenido en:
padre
7837d51ab6
commit
38f31bb21f
@ -173,7 +173,7 @@ int read_file(char *filename, point_t **points, unsigned int *n) {
|
||||
int j = 0;
|
||||
struct stat statbuff;
|
||||
|
||||
stat(filename, &statbuff);
|
||||
lstat(filename, &statbuff);
|
||||
if (access(filename, F_OK) || !S_ISREG(statbuff.st_mode)) {
|
||||
fprintf(stderr, "Error: El archivo \"%s\" no existe!\n", filename);
|
||||
return 1;
|
||||
|
Cargando…
Referencia en una nueva incidencia
Block a user