]> git.ipfire.org Git - thirdparty/autoconf.git/commitdiff
Avoid one-argument ‘main’
authorPaul Eggert <eggert@cs.ucla.edu>
Fri, 7 Aug 2020 00:40:49 +0000 (17:40 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Fri, 7 Aug 2020 00:52:49 +0000 (17:52 -0700)
* tests/autotest.at (C unit tests, C unit tests (EXEEXT)):
Avoid ‘int main (int argc)’ as the C standard says this
is not portable.

tests/autotest.at

index dbd86460c284b67718648619348273465dd50e26..5519e9c7b5ced0b2c608abaa51faad893cfbcf4a 100644 (file)
@@ -1904,7 +1904,7 @@ AC_OUTPUT
 
 # Test file
 AT_DATA([testprog.c],
-[[int main(int argc) { return argc == 2 ? 0 : 1; }
+[[int main (int argc, char **argv) { return argc == 2 ? 0 : 1; }
 ]])
 
 # Testsuite
@@ -1956,7 +1956,7 @@ AC_OUTPUT
 
 # Test file
 AT_DATA([testprog.c],
-[[int main(int argc) { return argc == 2 ? 0 : 1; }
+[[int main (int argc, char **argv) { return argc == 2 ? 0 : 1; }
 ]])
 
 # Testsuite