Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fixed confusing error messages.
  • Loading branch information
icculus committed Jun 27, 2004
1 parent 2d38d57 commit 33f6cd8
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion platform_unix.c
Expand Up @@ -295,6 +295,7 @@ static int parse_info_dot_plist(const char *ident,
long fsize;
int retval = 0;
FILE *io = NULL;
int knowver = 0;

if ( !get_file_size(fname, &fsize) ) goto parse_info_plist_bailed;
if ( (mem = malloc(fsize + 1)) == NULL ) goto parse_info_plist_bailed;
Expand Down Expand Up @@ -325,6 +326,7 @@ static int parse_info_dot_plist(const char *ident,
ptr = find_info_plist_version(mem);
if (ptr != NULL)
{
knowver = 1;
retval = version_ok(ptr, version);
if (retval == -1)
_fatal("You seem to be all patched up already!");
Expand All @@ -340,7 +342,7 @@ static int parse_info_dot_plist(const char *ident,
if (io != NULL)
fclose(io);

if (retval == 0) _fatal("Can't determine product's installed version.");
if (!knowver) _fatal("Can't determine product's installed version.");
return(retval);
} /* parse_info_dot_plist */

Expand Down

0 comments on commit 33f6cd8

Please sign in to comment.