loadJPEG: fix fread() return value testing

According to the fread() manpage, successful fread() call will return 1 and not len in this case.