diff --git a/library/stdlib_assertion_failure.c b/library/stdlib_assertion_failure.c index 1c929aa..b918093 100644 --- a/library/stdlib_assertion_failure.c +++ b/library/stdlib_assertion_failure.c @@ -1,5 +1,5 @@ /* - * $Id: stdlib_assertion_failure.c,v 1.10 2005-03-19 11:06:57 obarthel Exp $ + * $Id: stdlib_assertion_failure.c,v 1.11 2005-11-20 19:04:10 obarthel Exp $ * * :ts=4 * @@ -101,7 +101,7 @@ __assertion_failure( es.es_StructSize = sizeof(es); es.es_Title = (STRPTR)__program_name; - es.es_TextFormat = (STRPTR)"Assertion of expression\n\"%s\"\nfailed in file \"%s\", line %ld."; + es.es_TextFormat = (STRPTR)"Assertion of condition\n\"%s\"\nfailed in file \"%s\", line %ld."; es.es_GadgetFormat = (STRPTR)"Sorry"; EasyRequest(NULL,&es,NULL, diff --git a/library/stdlib_malloc.c b/library/stdlib_malloc.c index 67f3c90..613a995 100644 --- a/library/stdlib_malloc.c +++ b/library/stdlib_malloc.c @@ -1,5 +1,5 @@ /* - * $Id: stdlib_malloc.c,v 1.15 2005-11-20 17:00:22 obarthel Exp $ + * $Id: stdlib_malloc.c,v 1.16 2005-11-20 19:04:10 obarthel Exp $ * * :ts=4 * @@ -116,7 +116,10 @@ __allocate_memory(size_t size,BOOL never_free,const char * UNUSED unused_file,in /* Zero length allocations are by default rejected. */ if(size == 0) + { + __set_errno(EINVAL); goto out; + } if(__free_memory_threshold > 0 && AvailMem(MEMF_ANY|MEMF_LARGEST) < __free_memory_threshold) {