Skip to content

Commit

Permalink
ferror() after fclose() bug
Browse files Browse the repository at this point in the history
fixed either a wrong value being returned, or a segfaule (depending on
how bionic handles its files)
  • Loading branch information
mionica committed Apr 30, 2015
1 parent 205ca32 commit e21bfd3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion xposed_service.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -765,7 +765,7 @@ status_t XposedService::readFile(const String16& filename16, int32_t offset, int
status_t err = ferror(f);
fclose(f);
if (errormsg) *errormsg = formatToString16("%s during fseek() to offset %d for %s", strerror(err), offset, filename);
return ferror(f);
return err;
}

// Read the file
Expand Down

0 comments on commit e21bfd3

Please sign in to comment.