Harinder Singh Dhanoa commented on a discussion on misc/bin2c/rtems-bin2c.c: 
https://gitlab.rtems.org/rtems/tools/rtems-tools/-/merge_requests/58#note_121855

 >  }
 >  
 > +char *read_license_file(const char *filename) {
 > +  FILE *file = fopen(filename, "r");
 > +  if (!file) {
 > +    perror("error: could not open license file");
 > +    exit(1);
 > +  }
 > +
 > +  if (fseek(file, 0, SEEK_END) != 0) {
 > +    perror("error: could not seek to end of license file");
 > +    fclose(file);
 > +    exit(1);
 > +  };
 > +
 > +  long length = ftell(file);

done.

-- 
View it on GitLab: 
https://gitlab.rtems.org/rtems/tools/rtems-tools/-/merge_requests/58#note_121855
You're receiving this email because of your account on gitlab.rtems.org.


_______________________________________________
bugs mailing list
bugs@rtems.org
http://lists.rtems.org/mailman/listinfo/bugs

Reply via email to