diff vidix/drivers/sis_bridge.c @ 17566:f580a7755ac5

Patch by Stefan Huehner / stefan % huehner ! org \ patch replaces '()' for the correct '(void)' in function declarations/prototypes which have no parameters. The '()' syntax tell thats there is a variable list of arguments, so that the compiler cannot check this. The extra CFLAG '-Wstrict-declarations' shows those cases. Comments about a similar patch applied to ffmpeg: That in C++ these mean the same, but in ANSI C the semantics are different; function() is an (obsolete) K&R C style forward declaration, it basically means that the function can have any number and any types of parameters, effectively completely preventing the compiler from doing any sort of type checking. -- Erik Slagter Defining functions with unspecified arguments is allowed but bad. With arguments unspecified the compiler can't report an error/warning if the function is called with incorrect arguments. -- M\ns Rullg\rd
author rathann
date Thu, 09 Feb 2006 14:08:03 +0000
parents 401b440a6d76
children
line wrap: on
line diff
--- a/vidix/drivers/sis_bridge.c	Thu Feb 09 10:23:51 2006 +0000
+++ b/vidix/drivers/sis_bridge.c	Thu Feb 09 14:08:03 2006 +0000
@@ -60,7 +60,7 @@
 
 
 /* sense connected devices on 30x bridge */
-static void sis_sense_30x()
+static void sis_sense_30x(void)
 {
     unsigned char backupP4_0d, backupP2_00, biosflag;
     unsigned char testsvhs_tempbl, testsvhs_tempbh;
@@ -356,7 +356,7 @@
 }
 
 
-static void sis_detect_crt1()
+static void sis_detect_crt1(void)
 {
     unsigned char CR32;
     unsigned char CRT1Detected = 0;
@@ -394,7 +394,7 @@
 }
 
 
-static void sis_detect_lcd()
+static void sis_detect_lcd(void)
 {
     unsigned char CR32, CR36, CR37;
 
@@ -413,7 +413,7 @@
 }
 
 
-static void sis_detect_tv()
+static void sis_detect_tv(void)
 {
     unsigned char SR16, SR38, CR32, CR38 = 0, CR79;
     int temp = 0;
@@ -517,7 +517,7 @@
 }
 
 
-static void sis_detect_crt2()
+static void sis_detect_crt2(void)
 {
     unsigned char CR32;
 
@@ -563,7 +563,7 @@
 
 
 /* Preinit: detect video bridge and sense connected devs */
-static void sis_detect_video_bridge()
+static void sis_detect_video_bridge(void)
 {
     int temp, temp1, temp2;
 
@@ -708,7 +708,7 @@
 
 
 /* detect video bridge type and sense connected devices */
-void sis_init_video_bridge()
+void sis_init_video_bridge(void)
 {
 
     sis_detect_video_bridge();