Merge remote-tracking branch 'origin/10.1' into 10.2

This commit is contained in:
Vicențiu Ciorbaru 2017-12-22 12:23:39 +02:00
commit 985d2d393c
87 changed files with 1806 additions and 350 deletions

View file

@ -487,8 +487,7 @@ int load_defaults(const char *conf_file, const char **groups,
easily command line options override options in configuration files
NOTES
In case of fatal error, the function will print a warning and do
exit(1)
In case of fatal error, the function will print a warning and returns 2
To free used memory one should call free_defaults() with the argument
that was put in *argv
@ -641,8 +640,7 @@ int my_load_defaults(const char *conf_file, const char **groups,
err:
fprintf(stderr,"Fatal error in defaults handling. Program aborted\n");
exit(1);
return 0; /* Keep compiler happy */
return 2;
}

View file

@ -109,7 +109,7 @@ void *my_malloc(size_t size, myf my_flags)
my_error(EE_OUTOFMEMORY, MYF(ME_BELL + ME_WAITTANG +
ME_NOREFRESH + ME_FATALERROR),size);
if (my_flags & MY_FAE)
exit(1);
abort();
}
else
{

View file

@ -45,18 +45,6 @@ int find_type_with_warning(const char *x, TYPELIB *typelib, const char *option)
}
int find_type_or_exit(const char *x, TYPELIB *typelib, const char *option)
{
int res;
if ((res= find_type_with_warning(x, typelib, option)) <= 0)
{
sf_leaking_memory= 1; /* no memory leak reports here */
exit(1);
}
return res;
}
/**
Search after a string in a list of strings. Endspace in x is not compared.