diff mbox

Fix missing function declaration warnings in yesterday's libobjc patch

Message ID 1306401268.305429184@www2.webmail.us
State New
Headers show

Commit Message

Nicola Pero May 26, 2011, 9:14 a.m. UTC
This patch fixes a problem with the patch from Richard/David that was committed yesterday;
presumably since the patch was originally written before the new libobjc API revamp, it was
still using objc_lookup_class(), which is not part of the Modern API, hence currently undeclared
in sendmsg.c.  I replaced it with the Modern API counter-part, which is objc_getClass(),
fixing the compiler warnings, and providing the compiler with the correct function declaration.

Applied to trunk.

Thanks
diff mbox

Patch

Index: sendmsg.c
===================================================================
--- sendmsg.c   (revision 174267)
+++ sendmsg.c   (working copy)
@@ -1111,7 +1111,7 @@ 
   else
     {
       /* Retreive the class from the meta class.  */
-      Class c = objc_lookup_class (cls->name);
+      Class c = objc_getClass (cls->name);
       assert (CLS_ISMETA (cls));
       assert (c);
       __objc_send_initialize (c);
Index: ChangeLog
===================================================================
--- ChangeLog   (revision 174267)
+++ ChangeLog   (working copy)
@@ -1,3 +1,8 @@ 
+2011-05-26  Nicola Pero  <nicola.pero@meta-innovation.com>
+
+       * sendmsg.c (__objc_install_dtable_for_class): Use objc_getClass,
+       not objc_lookupClass.
+
 2011-05-25  Richard Frith-Macdonald <rfm@gnu.org>
            David Ayers  <ayers@fsfe.org>