Files
pkgsrc-ng/devel/librfuncs/patches/patch-aa
2013-09-26 17:14:40 +02:00

25 lines
709 B
Plaintext

$NetBSD: patch-aa,v 1.1 2006/03/01 15:58:03 drochner Exp $
--- src/getenv_r.c.orig 2006-03-01 16:06:43.000000000 +0100
+++ src/getenv_r.c
@@ -39,7 +39,8 @@ int getenv_r(const char *name, char *get
if (envList == NULL)
{
/* The string name was not found in the environment. */
- retVal = ENOENT;
+ errno = ENOENT;
+ retVal = -1;
}
else
{
@@ -50,7 +51,8 @@ int getenv_r(const char *name, char *get
Insufficient storage was supplied via getenvbuf and buflen to
contain the value for the specified name.
*/
- retVal = ERANGE;
+ errno = ERANGE;
+ retVal = -1;
}
else
{