Skip to content

Commit

Permalink
builtin-log: typefix for recent format-patch changes.
Browse files Browse the repository at this point in the history
Signed-off-by: Junio C Hamano <junkio@cox.net>
  • Loading branch information
Junio C Hamano committed Jul 15, 2006
1 parent da56645 commit 76af073
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions builtin-log.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@
#include "revision.h"
#include "log-tree.h"
#include "builtin.h"
#include <time.h>
#include <sys/time.h>

/* this is in builtin-diff.c */
void add_head(struct rev_info *revs);
Expand Down Expand Up @@ -233,8 +235,9 @@ static void gen_message_id(char *dest, unsigned int length, char *base)
const char *email_end = strrchr(committer, '>');
if(!email_start || !email_end || email_start > email_end - 1)
die("Could not extract email from committer identity.");
snprintf(dest, length, "%s.%u.git.%.*s", base, time(NULL),
email_end - email_start - 1, email_start + 1);
snprintf(dest, length, "%s.%lu.git.%.*s", base,
(unsigned long) time(NULL),
(int)(email_end - email_start - 1), email_start + 1);
}

int cmd_format_patch(int argc, const char **argv, char **envp)
Expand All @@ -249,7 +252,7 @@ int cmd_format_patch(int argc, const char **argv, char **envp)
int keep_subject = 0;
int ignore_if_in_upstream = 0;
int thread = 0;
char *in_reply_to = NULL;
const char *in_reply_to = NULL;
struct diff_options patch_id_opts;
char *add_signoff = NULL;
char message_id[1024];
Expand Down

0 comments on commit 76af073

Please sign in to comment.