]> sourceware.org Git - newlib-cygwin.git/commitdiff
* cygheap.cc: Add some __stdcall decoration where appropriate.
authorChristopher Faylor <me@cgf.cx>
Thu, 10 Feb 2011 02:22:36 +0000 (02:22 +0000)
committerChristopher Faylor <me@cgf.cx>
Thu, 10 Feb 2011 02:22:36 +0000 (02:22 +0000)
* lib/cygwin_crt0.c: __attribute -> __attribute__.

winsup/cygwin/ChangeLog
winsup/cygwin/cygheap.cc
winsup/cygwin/lib/cygwin_crt0.c

index 8642b762df16693906aa2ca4fbac24971c81fcfd..8823eb880ddae8ab60d36b9ce38a913c38491793 100644 (file)
@@ -1,3 +1,8 @@
+2011-02-09  Christopher Faylor  <me+cygwin@cgf.cx>
+
+       * cygheap.cc: Add some __stdcall decoration where appropriate.
+       * lib/cygwin_crt0.c: __attribute -> __attribute__.
+
 2011-02-09  Christopher Faylor  <me+cygwin@cgf.cx>
 
        * hookapi.cc (hook_or_detect_cygwin): Prevent i from being considered
index 623fd765d41012fb869958fb512be40e72c0dfbc..5fee0be8e873c54b072ced3f19c2ddcddcc485e8 100644 (file)
@@ -178,10 +178,10 @@ cygheap_init ()
 
 /* Copyright (C) 1997, 2000 DJ Delorie */
 
-static void *_cmalloc (unsigned size) __attribute ((regparm(1)));
-static void *__stdcall _crealloc (void *ptr, unsigned size) __attribute ((regparm(2)));
+static void *__stdcall _cmalloc (unsigned size) __attribute__ ((regparm(1)));
+static void *__stdcall _crealloc (void *ptr, unsigned size) __attribute__ ((regparm(2)));
 
-static void *__stdcall
+static void *__stdcall __attribute__ ((regparm(1)))
 _cmalloc (unsigned size)
 {
   _cmalloc_entry *rvc;
@@ -215,7 +215,7 @@ _cmalloc (unsigned size)
   return rvc->data;
 }
 
-static void __stdcall
+static void __stdcall __attribute__ ((regparm(1)))
 _cfree (void *ptr)
 {
   cygheap_protect.acquire ();
@@ -226,7 +226,7 @@ _cfree (void *ptr)
   cygheap_protect.release ();
 }
 
-static void *__stdcall
+static void *__stdcall __attribute__ ((regparm(2)))
 _crealloc (void *ptr, unsigned size)
 {
   void *newptr;
@@ -309,19 +309,19 @@ crealloc (void *s, DWORD n, const char *fn)
   return creturn (t, c, n, fn);
 }
 
-extern "C" void *__stdcall
+extern "C" void *__stdcall  __attribute__ ((regparm(2)))
 crealloc (void *s, DWORD n)
 {
   return crealloc (s, n, NULL);
 }
 
-extern "C" void *__stdcall
+extern "C" void *__stdcall  __attribute__ ((regparm(2)))
 crealloc_abort (void *s, DWORD n)
 {
   return crealloc (s, n, "crealloc");
 }
 
-extern "C" void __stdcall
+extern "C" void __stdcall __attribute__ ((regparm(1)))
 cfree (void *s)
 {
   assert (!inheap (s));
@@ -329,7 +329,7 @@ cfree (void *s)
   MALLOC_CHECK;
 }
 
-extern "C" void __stdcall
+extern "C" void __stdcall __attribute__ ((regparm(2)))
 cfree_and_set (char *&s, char *what)
 {
   if (s && s != almost_null)
@@ -349,19 +349,19 @@ ccalloc (cygheap_types x, DWORD n, DWORD size, const char *fn)
   return creturn (x, c, n, fn);
 }
 
-extern "C" void *__stdcall
+extern "C" void *__stdcall __attribute__ ((regparm(3)))
 ccalloc (cygheap_types x, DWORD n, DWORD size)
 {
   return ccalloc (x, n, size, NULL);
 }
 
-extern "C" void *__stdcall
+extern "C" void *__stdcall __attribute__ ((regparm(3)))
 ccalloc_abort (cygheap_types x, DWORD n, DWORD size)
 {
   return ccalloc (x, n, size, "ccalloc");
 }
 
-extern "C" PWCHAR __stdcall
+extern "C" PWCHAR __stdcall __attribute__ ((regparm(1)))
 cwcsdup (const PWCHAR s)
 {
   MALLOC_CHECK;
@@ -373,7 +373,7 @@ cwcsdup (const PWCHAR s)
   return p;
 }
 
-extern "C" PWCHAR __stdcall
+extern "C" PWCHAR __stdcall __attribute__ ((regparm(1)))
 cwcsdup1 (const PWCHAR s)
 {
   MALLOC_CHECK;
@@ -385,7 +385,7 @@ cwcsdup1 (const PWCHAR s)
   return p;
 }
 
-extern "C" char *__stdcall
+extern "C" char *__stdcall __attribute__ ((regparm(1)))
 cstrdup (const char *s)
 {
   MALLOC_CHECK;
@@ -397,7 +397,7 @@ cstrdup (const char *s)
   return p;
 }
 
-extern "C" char *__stdcall
+extern "C" char *__stdcall __attribute__ ((regparm(1)))
 cstrdup1 (const char *s)
 {
   MALLOC_CHECK;
index a3aa077739e55e96ce414e016290348eff84ca95..e96a066506d5b331d45a3da783e791d10b27cbe4 100644 (file)
@@ -12,7 +12,7 @@ details. */
 #include "crt0.h"
 
 extern void __stdcall _dll_crt0 ()
-  __declspec (dllimport) __attribute ((noreturn));
+  __declspec (dllimport) __attribute__ ((noreturn));
 
 /* for main module */
 void
This page took 0.037722 seconds and 5 git commands to generate.