* The following bugs are resolved with this release:
6652, 12926, 14132, 14138, 14171, 15215, 15884, 17266, 17344, 17363,
- 17370, 17371, 17411, 17460, 17475, 17485, 17501, 17508, 17522, 17555.
+ 17370, 17371, 17411, 17460, 17475, 17485, 17501, 17506, 17508, 17522,
+ 17555.
* New locales: tu_IN, bh_IN.
\f
exit (1);
}
-#ifndef EXPECTED_SIGNAL
- /* We don't expect any signal. */
-# define EXPECTED_SIGNAL 0
-#endif
- if (WTERMSIG (status) != EXPECTED_SIGNAL)
+ /* Process terminated normaly without timeout etc. */
+ if (WIFEXITED (status))
{
- if (EXPECTED_SIGNAL != 0)
- {
- if (WTERMSIG (status) == 0)
- printf ("Expected signal '%s' from child, got none\n",
- strsignal (EXPECTED_SIGNAL));
- else
- printf ("Incorrect signal from child: got `%s', need `%s'\n",
- strsignal (WTERMSIG (status)),
- strsignal (EXPECTED_SIGNAL));
- }
- else
- printf ("Didn't expect signal from child: got `%s'\n",
- strsignal (WTERMSIG (status)));
- exit (1);
- }
-
- /* Simply exit with the return value of the test. */
#ifndef EXPECTED_STATUS
- return WEXITSTATUS (status);
+# ifndef EXPECTED_SIGNAL
+ /* Simply exit with the return value of the test. */
+ return WEXITSTATUS (status);
+# else
+ printf ("Expected signal '%s' from child, got none\n",
+ strsignal (EXPECTED_SIGNAL));
+ exit (1);
+# endif
#else
- if (WEXITSTATUS (status) != EXPECTED_STATUS)
+ if (WEXITSTATUS (status) != EXPECTED_STATUS)
+ {
+ printf ("Expected status %d, got %d\n",
+ EXPECTED_STATUS, WEXITSTATUS (status));
+ exit (1);
+ }
+
+ return 0;
+#endif
+ }
+ /* Process was killed by timer or other signal. */
+ else
{
- printf ("Expected status %d, got %d\n",
- EXPECTED_STATUS, WEXITSTATUS (status));
+#ifndef EXPECTED_SIGNAL
+ printf ("Didn't expect signal from child: got `%s'\n",
+ strsignal (WTERMSIG (status)));
exit (1);
- }
+#else
+ if (WTERMSIG (status) != EXPECTED_SIGNAL)
+ {
+ printf ("Incorrect signal from child: got `%s', need `%s'\n",
+ strsignal (WTERMSIG (status)),
+ strsignal (EXPECTED_SIGNAL));
+ exit (1);
+ }
- return 0;
+ return 0;
#endif
+ }
}