summaryrefslogtreecommitdiffstats
path: root/testsuites/psxtests/psxsysconf/init.c
diff options
context:
space:
mode:
authorRalf Corsepius <ralf.corsepius@rtems.org>2009-10-29 05:45:49 +0000
committerRalf Corsepius <ralf.corsepius@rtems.org>2009-10-29 05:45:49 +0000
commitdc4fbb81d1438794e7e9f16b70bd1cb8abc4c64e (patch)
tree46eb5acad6c8738037a69fab2cc850d9c3a1f6e7 /testsuites/psxtests/psxsysconf/init.c
parent2009-10-29 Ralf Corsépius <ralf.corsepius@rtems.org> (diff)
downloadrtems-dc4fbb81d1438794e7e9f16b70bd1cb8abc4c64e.tar.bz2
Comment out sysconf(LONG_MAX) check (not useful).
Change sysconf(0x12345678) check into sysconf(INT_MAX) for better 16bit compliance.
Diffstat (limited to '')
-rw-r--r--testsuites/psxtests/psxsysconf/init.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/testsuites/psxtests/psxsysconf/init.c b/testsuites/psxtests/psxsysconf/init.c
index c220657847..1d6bdb06d2 100644
--- a/testsuites/psxtests/psxsysconf/init.c
+++ b/testsuites/psxtests/psxsysconf/init.c
@@ -28,11 +28,17 @@ void *POSIX_Init(
puts( "sysconf -- bad configuration parameter - negative" );
sc = sysconf( -1 );
fatal_posix_service_status_errno( sc, EINVAL, "bad conf name" );
-
+
+#if UNUSED
+/* FIXME: This test doesn't make sense.
+ * On targets with sizeof(int) < sizeof(long), compilation will fail,
+ * On targets with sizeof(int) == sizeof(long) the call is valid.
+ */
puts( "sysconf -- bad configuration parameter - too large" );
sc = sysconf( LONG_MAX );
fatal_posix_service_status_errno( sc, EINVAL, "bad conf name" );
-
+#endif
+
sc = sysconf( _SC_CLK_TCK );
printf( "sysconf - _SC_CLK_TCK=%ld\n", sc );
if ( sc == -1 )
@@ -58,7 +64,7 @@ void *POSIX_Init(
if ( sc == -1 )
rtems_test_exit(0);
- sc = sysconf( 0x12345678 );
+ sc = sysconf( INT_MAX );
printf( "sysconf - bad parameter = %ld errno=%s\n", sc, strerror(errno) );
if ( (sc != -1) || (errno != EINVAL) )
rtems_test_exit(0);