Skip to content

Commit

Permalink
Merged some lemon diffs from sqlite's fossil repo: Visual Studio comp…
Browse files Browse the repository at this point in the history
…ile fixes.
  • Loading branch information
icculus committed Mar 3, 2010
1 parent f54ce88 commit 59a357d
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions misc/lemon.c
Expand Up @@ -51,7 +51,6 @@ static void LemonAtExit(void)
if (!successful_exit) {
remove(made_files[i]);
}
free((void *) made_files[i]);
}
free(made_files);
made_files_count = 0;
Expand Down Expand Up @@ -408,7 +407,7 @@ static int actioncmp(
rc = ap1->x.rp->index - ap2->x.rp->index;
}
if( rc==0 ){
rc = ap2 - ap1;
rc = (int) (ap2 - ap1);
}
return rc;
}
Expand Down Expand Up @@ -2817,10 +2816,9 @@ PRIVATE FILE *file_open(
if(( *mode=='w' ) && (strcmp(suffix, ".out") != 0)){
const char **ptr = (const char **)
realloc(made_files, sizeof (const char **) * (made_files_count + 1));
char *fname = strdup(lemp->outname);
const char *fname = Strsafe(lemp->outname);
if ((ptr == NULL) || (fname == NULL)) {
free(ptr);
free(fname);
memory_error();
}
made_files = ptr;
Expand Down

0 comments on commit 59a357d

Please sign in to comment.