Skip to content

Commit

Permalink
Merge branch 'maint'
Browse files Browse the repository at this point in the history
* maint:
  ctype.c: protect tiny C preprocessor constants
  index-pack: be careful after fixing up the header/footer
  • Loading branch information
Junio C Hamano committed Aug 27, 2008
2 parents cdc7e38 + c67b1fa commit bb34ca5
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 1 deletion.
1 change: 0 additions & 1 deletion builtin-pack-objects.c
Original file line number Diff line number Diff line change
Expand Up @@ -499,7 +499,6 @@ static void write_pack_file(void)
} else {
int fd = sha1close(f, NULL, 0);
fixup_pack_header_footer(fd, sha1, pack_tmp_name, nr_written);
fsync_or_die(fd, pack_tmp_name);
close(fd);
}

Expand Down
5 changes: 5 additions & 0 deletions ctype.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@
*/
#include "cache.h"

/* Just so that no insane platform contaminate namespace with these symbols */
#undef SS
#undef AA
#undef DD

#define SS GIT_SPACE
#define AA GIT_ALPHA
#define DD GIT_DIGIT
Expand Down
1 change: 1 addition & 0 deletions pack-write.c
Original file line number Diff line number Diff line change
Expand Up @@ -179,6 +179,7 @@ void fixup_pack_header_footer(int pack_fd,

SHA1_Final(pack_file_sha1, &c);
write_or_die(pack_fd, pack_file_sha1, 20);
fsync_or_die(pack_fd, pack_name);
}

char *index_pack_lockfile(int ip_out)
Expand Down

0 comments on commit bb34ca5

Please sign in to comment.