cURL / Mailing Lists / curl-library / Single Mail

curl-library

[PATCH] get rid of 'control reaches end of non-void function' warning

From: Guenter Knauf <eflash_at_gmx.net>
Date: Tue, 22 Jun 2004 19:15:57 +0200

Hi,
this simple patch makes gcc happy and avoids the waring control 'reaches end of non-void function' in function `ToHour' with some gcc versions:

--- getdate.y.orig 2004-06-22 12:00:06.000000000 +0200
+++ getdate.y 2004-06-22 18:16:50.000000000 +0200
@@ -724,7 +724,8 @@
     default:
       abort ();
     }
- /* NOTREACHED */
+ /* NOTREACHED - but make gcc happy! */
+ return -1;
 }
 
 static int
-------------------------------------------------------------------
--- getdate.c.cvs.orig 2004-06-22 17:36:07.000000000 +0200
+++ getdate.c.cvs 2004-06-22 18:16:17.000000000 +0200
@@ -1758,7 +1758,8 @@
     default:
       abort ();
     }
- /* NOTREACHED */
+ /* NOTREACHED - but make gcc happy! */
+ return -1;
 }
 
 static int

Guenter.

Received on 2004-06-22