Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCorinna Vinschen <corinna@vinschen.de>2002-06-13 20:30:18 +0400
committerCorinna Vinschen <corinna@vinschen.de>2002-06-13 20:30:18 +0400
commit0e6d80e4fa95a35c1a871e4aed5b3153529b8594 (patch)
treea14e4cd4950f5b3acd4c132b12cad9a0cedcf444 /winsup/cygwin/environ.cc
parent1f1fb4210d7000de5d9ed7229c08b927a4a9df87 (diff)
* cygheap.cc (cygheap_user::set_name): Revert previous change.
* environ.cc (spenv::retrieve): Check return value of call to cygheap->user.*from_cygheap().
Diffstat (limited to 'winsup/cygwin/environ.cc')
-rw-r--r--winsup/cygwin/environ.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/winsup/cygwin/environ.cc b/winsup/cygwin/environ.cc
index da96b5245..4d535e436 100644
--- a/winsup/cygwin/environ.cc
+++ b/winsup/cygwin/environ.cc
@@ -786,7 +786,8 @@ spenv::retrieve (bool no_envblock, const char *const envname, int len)
/* Make a FOO=BAR entry from the value returned by the cygheap_user
method. */
- p = (cygheap->user.*from_cygheap) ();
+ if (!(p = (cygheap->user.*from_cygheap) ()))
+ return NULL;
int namelen = strlen (name);
char *s = (char *) cmalloc (HEAP_1_STR, namelen + strlen (p) + 1);
strcpy (s, name);