New answers tagged

1 vote
Accepted

Recover runs, but leaks 472 bytes in 1 block

Whenever valgrind points to an fopen as the source of a memory leak, it almost always means that a file wasn't closed. For each block, it's one file still open. Looking at your code, and knowing the ...
  • 66.2k
1 vote
Accepted

Code for Good ol' Recover returns all fifty images (000-049), but doesn't pass Check50

actually, the code seems to be creating 52 files, numbered 000 to 051, so something is amiss. Perhaps you should consider reworking the logic a little bit? Hint: why open an output file before the ...
  • 66.2k
0 votes
Accepted

Pset 4 Recover finding 51 files

There are a few problems going on here. Let's start with the easy ones. The files are incorrectly named. There's not supposed to be an "e' in jpg. Second, the file numbering starts at 0, not 1. ...
  • 66.2k

Top 50 recent answers are included