delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/2011/09/16/06:59:49

X-Authentication-Warning: delorie.com: mail set sender to djgpp-workers-bounces using -f
X-Recipient: djgpp-workers AT delorie DOT com
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=gmail.com; s=gamma;
h=mime-version:date:message-id:subject:from:to:content-type;
bh=x+yqmS9cU0NnyF9zJgbY+/EhpQB3jGIDxLY5CZLjGYk=;
b=e3h9B/vGFHonlj3xVAOBC+syQ+OZsqbAJkGTRHJxZE+KUFTG86TzVWDl/xBH3RElvo
bRLr+BNorNpW2IQSpJD1KaWOEIkFxpvQpBYKdghO6VvNDOSeQIchJmdlzTBIE+98tYxt
MrUSNAXU+w4rPNaljKFqNwsWSP0Pe/Wbf70ko=
MIME-Version: 1.0
Date: Fri, 16 Sep 2011 13:59:30 +0300
Message-ID: <CAA2C=vAS=ZXeN=FsucnEjyOnu9sRSRLodnsbERVxdbwhq03_Ag@mail.gmail.com>
Subject: more NULL fixes
From: Ozkan Sezer <sezeroz AT gmail DOT com>
To: djgpp-workers AT delorie DOT com
Reply-To: djgpp-workers AT delorie DOT com

--0016364ee2e043e91004ad0ce33b
Content-Type: text/plain; charset=ISO-8859-1

These two showed themselves after yesterday's stdlib.h NULL patch.


Index: src/libc/compat/mntent/mntent.c
===================================================================
RCS file: /cvs/djgpp/djgpp/src/libc/compat/mntent/mntent.c,v
retrieving revision 1.11
diff -u -p -r1.11 mntent.c
--- src/libc/compat/mntent/mntent.c	2 Aug 2009 05:37:01 -0000	1.11
+++ src/libc/compat/mntent/mntent.c	16 Sep 2011 10:55:49 -0000
@@ -871,7 +871,7 @@ endmntent(FILE *filep)
   if (filep != (FILE *)1)
     {
       errno = EBADF;    /* fake errno for invalid handle */
-      return NULL;
+      return 0;
     }
   drive_number = 0;
   skip_drive_b = 0;
Index: src/libc/compat/stdlib/alloca.c
===================================================================
RCS file: /cvs/djgpp/djgpp/src/libc/compat/stdlib/alloca.c,v
retrieving revision 1.1
diff -u -p -r1.1 alloca.c
--- src/libc/compat/stdlib/alloca.c	11 Jan 1996 04:02:06 -0000	1.1
+++ src/libc/compat/stdlib/alloca.c	16 Sep 2011 10:55:49 -0000
@@ -34,8 +34,6 @@

 #define ADDRESS_FUNCTION(arg) &(arg)

-#define	NULL	0
-
 /* Define STACK_DIRECTION if you know the direction of stack
    growth for your system; otherwise it will be automatically
    deduced at run-time.



Regards.

--
O.S.

--0016364ee2e043e91004ad0ce33b
Content-Type: application/octet-stream; name="null_fixes.diff"
Content-Disposition: attachment; filename="null_fixes.diff"
Content-Transfer-Encoding: base64
X-Attachment-Id: f_gsn21t7j0

SW5kZXg6IHNyYy9saWJjL2NvbXBhdC9tbnRlbnQvbW50ZW50LmMKPT09PT09PT09PT09PT09PT09
PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PQpSQ1MgZmls
ZTogL2N2cy9kamdwcC9kamdwcC9zcmMvbGliYy9jb21wYXQvbW50ZW50L21udGVudC5jLHYKcmV0
cmlldmluZyByZXZpc2lvbiAxLjExCmRpZmYgLXUgLXAgLXIxLjExIG1udGVudC5jCi0tLSBzcmMv
bGliYy9jb21wYXQvbW50ZW50L21udGVudC5jCTIgQXVnIDIwMDkgMDU6Mzc6MDEgLTAwMDAJMS4x
MQorKysgc3JjL2xpYmMvY29tcGF0L21udGVudC9tbnRlbnQuYwkxNiBTZXAgMjAxMSAxMDo1NTo0
OSAtMDAwMApAQCAtODcxLDcgKzg3MSw3IEBAIGVuZG1udGVudChGSUxFICpmaWxlcCkKICAgaWYg
KGZpbGVwICE9IChGSUxFICopMSkKICAgICB7CiAgICAgICBlcnJubyA9IEVCQURGOyAgICAvKiBm
YWtlIGVycm5vIGZvciBpbnZhbGlkIGhhbmRsZSAqLwotICAgICAgcmV0dXJuIE5VTEw7CisgICAg
ICByZXR1cm4gMDsKICAgICB9CiAgIGRyaXZlX251bWJlciA9IDA7CiAgIHNraXBfZHJpdmVfYiA9
IDA7CkluZGV4OiBzcmMvbGliYy9jb21wYXQvc3RkbGliL2FsbG9jYS5jCj09PT09PT09PT09PT09
PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0KUkNT
IGZpbGU6IC9jdnMvZGpncHAvZGpncHAvc3JjL2xpYmMvY29tcGF0L3N0ZGxpYi9hbGxvY2EuYyx2
CnJldHJpZXZpbmcgcmV2aXNpb24gMS4xCmRpZmYgLXUgLXAgLXIxLjEgYWxsb2NhLmMKLS0tIHNy
Yy9saWJjL2NvbXBhdC9zdGRsaWIvYWxsb2NhLmMJMTEgSmFuIDE5OTYgMDQ6MDI6MDYgLTAwMDAJ
MS4xCisrKyBzcmMvbGliYy9jb21wYXQvc3RkbGliL2FsbG9jYS5jCTE2IFNlcCAyMDExIDEwOjU1
OjQ5IC0wMDAwCkBAIC0zNCw4ICszNCw2IEBACiAKICNkZWZpbmUgQUREUkVTU19GVU5DVElPTihh
cmcpICYoYXJnKQogCi0jZGVmaW5lCU5VTEwJMAotCiAvKiBEZWZpbmUgU1RBQ0tfRElSRUNUSU9O
IGlmIHlvdSBrbm93IHRoZSBkaXJlY3Rpb24gb2Ygc3RhY2sKICAgIGdyb3d0aCBmb3IgeW91ciBz
eXN0ZW07IG90aGVyd2lzZSBpdCB3aWxsIGJlIGF1dG9tYXRpY2FsbHkKICAgIGRlZHVjZWQgYXQg
cnVuLXRpbWUuCg==
--0016364ee2e043e91004ad0ce33b--

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019