summaryrefslogtreecommitdiffstats
path: root/test/stream_test.c
diff options
context:
space:
mode:
Diffstat (limited to 'test/stream_test.c')
-rw-r--r--test/stream_test.c38
1 files changed, 12 insertions, 26 deletions
diff --git a/test/stream_test.c b/test/stream_test.c
index 167bda1..239c2c6 100644
--- a/test/stream_test.c
+++ b/test/stream_test.c
@@ -11,8 +11,6 @@
* Modifications:
* Thomas Radke, Thursday, October 26, 2000
* Made it compiling under Windows.
- * Thomas Radke, Wednesday, November 8, 2000
- * Use _exit(2) instead of return() in the sender and receiver.
*
*/
@@ -86,7 +84,7 @@ static int sender (void)
if (fapl < 0)
{
fprintf (stderr, "sender: couldn't create file access property list\n");
- _exit (-1);
+ return (-1);
}
status = H5Pset_fapl_stream (fapl, NULL);
@@ -95,7 +93,7 @@ static int sender (void)
fprintf (stderr, "sender: couldn't set file access property list "
"for Stream VFD\n");
H5Pclose (fapl);
- _exit (-2);
+ return (-2);
}
/*
@@ -110,7 +108,7 @@ static int sender (void)
{
fprintf (stderr, "sender: couldn't create dataspace\n");
H5Pclose (fapl);
- _exit (-3);
+ return (-3);
}
/*
@@ -124,7 +122,7 @@ static int sender (void)
"%d integers\n", i);
H5Sclose (dataspace);
H5Pclose (fapl);
- _exit (-4);
+ return (-4);
}
while (--i >= 0)
{
@@ -144,7 +142,7 @@ static int sender (void)
free (data);
H5Sclose (dataspace);
H5Pclose (fapl);
- _exit (-5);
+ return (-5);
}
/*
@@ -160,7 +158,7 @@ static int sender (void)
H5Fclose (file);
H5Sclose (dataspace);
H5Pclose (fapl);
- _exit (-6);
+ return (-6);
}
/*
@@ -178,7 +176,7 @@ static int sender (void)
H5Sclose (dataspace);
H5Pclose (fapl);
fprintf (stderr, "sender: couldn't write dataset\n");
- _exit (-7);
+ return (-7);
}
/*
@@ -194,12 +192,6 @@ static int sender (void)
H5Pclose (fapl);
free (data);
- _exit (0);
-
- /*
- * This is just to get rid of the compiler warning
- * 'function does not return a value.
- */
return (0);
}
@@ -227,7 +219,7 @@ static int receiver (void)
if (fapl < 0)
{
fprintf (stderr, "receiver: couldn't create file access property list\n");
- _exit (-1);
+ return (-1);
}
status = H5Pset_fapl_stream (fapl, NULL);
@@ -235,7 +227,7 @@ static int receiver (void)
{
fprintf (stderr, "receiver: couldn't set file access property list "
"for Stream VFD\n");
- _exit (-2);
+ return (-2);
}
/*
@@ -249,7 +241,7 @@ static int receiver (void)
if (file < 0)
{
fprintf (stderr, "receiver: couldn't open file from '%s'\n", FILENAME);
- _exit (-3);
+ return (-3);
}
/*
@@ -260,7 +252,7 @@ static int receiver (void)
if (dataset < 0)
{
fprintf (stderr, "receiver: couldn't open dataset '%s'\n", DATASETNAME);
- _exit (-4);
+ return (-4);
}
/*
@@ -327,13 +319,7 @@ static int receiver (void)
free (data);
- _exit (-nerrors);
-
- /*
- * This is just to get rid of the compiler warning
- * 'function does not return a value.
- */
- return (0);
+ return (-nerrors);
}