aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--winsup/cygwin/ChangeLog4
-rw-r--r--winsup/cygwin/external.cc7
2 files changed, 7 insertions, 4 deletions
diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog
index b0672ee..80385b9 100644
--- a/winsup/cygwin/ChangeLog
+++ b/winsup/cygwin/ChangeLog
@@ -1,3 +1,7 @@
+2002-11-21 Igor Pechtchanski <pechtcha@cs.nyu.edu>
+
+ * external.cc (cygwin_internal): Fix va_arg references.
+
2002-11-21 Christopher Faylor <cgf@redhat.com>
* exceptions.cc (sigthread::get_winapi_lock): Just do standard 'give up
diff --git a/winsup/cygwin/external.cc b/winsup/cygwin/external.cc
index 406786d..85f4032 100644
--- a/winsup/cygwin/external.cc
+++ b/winsup/cygwin/external.cc
@@ -182,7 +182,7 @@ cygwin_internal (cygwin_getinfo_types t, ...)
return (DWORD) fillout_pinfo (va_arg (arg, pid_t), 1);
case CW_INIT_EXCEPTIONS:
- init_exceptions ((exception_list *) arg);
+ init_exceptions (va_arg (arg, exception_list *));
return 0;
case CW_GET_CYGDRIVE_INFO:
@@ -196,16 +196,15 @@ cygwin_internal (cygwin_getinfo_types t, ...)
case CW_SET_CYGWIN_REGISTRY_NAME:
{
-# define cr ((char *) arg)
+ const char *cr = va_arg (arg, char *);
if (check_null_empty_str_errno (cr))
return (DWORD) NULL;
cygheap->cygwin_regname = (char *) crealloc (cygheap->cygwin_regname,
strlen (cr) + 1);
strcpy (cygheap->cygwin_regname, cr);
+ }
case CW_GET_CYGWIN_REGISTRY_NAME:
return (DWORD) cygheap->cygwin_regname;
-# undef cr
- }
case CW_STRACE_TOGGLE:
{