Skip to content

Commit

Permalink
tar2qfile: Break early if directory headers sent already
Browse files Browse the repository at this point in the history
There is no reason to continue a loop if subsequent iterations will not
have useful effects.

(cherry picked from commit 1a2cd93)
  • Loading branch information
DemiMarie authored and marmarek committed Nov 5, 2024
1 parent 01e8ac5 commit e8084cb
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions qubes-rpc/tar2qfile.c
Original file line number Diff line number Diff line change
Expand Up @@ -750,6 +750,7 @@ ustar_rd (int fd, struct file_header * untrusted_hdr, char *buf, struct stat * s
fprintf(stderr,"Directory headers already sent\n");
#endif
dir_found=1;
break;
}
}
if (dir_found == 0) {
Expand Down

0 comments on commit e8084cb

Please sign in to comment.