I am trying to open a directory, and then open a file named \"YouTubeSign\", directory opens fine, but for some reason fopen() on the file fails even if the file exists; any ide
You have to pass an absolute file name when you use fopen(), composed with the directory name and file base name, e.g.:
fopen()
char abs_path[PATH_MAX]; // ... snprintf(abs_path, PATH_MAX, "%s/%s", argv[1], in_file->d_name); signature = fopen(abs_path, "r");