diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2012-10-07 17:11:30 +0200 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2012-10-07 17:11:30 +0200 |
commit | 39d7d51fe3c466816d70184da06b957d6c8fdbcc (patch) | |
tree | 2791850eaa1ea20a0a0ed9da779bcf60ecdb7880 /testsuites | |
parent | Filesystem: Reject removal of root nodes (diff) | |
download | rtems-39d7d51fe3c466816d70184da06b957d6c8fdbcc.tar.bz2 |
fstests/fsimfsgeneric01: Avoid global state
Diffstat (limited to 'testsuites')
-rw-r--r-- | testsuites/fstests/fsimfsgeneric01/init.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/testsuites/fstests/fsimfsgeneric01/init.c b/testsuites/fstests/fsimfsgeneric01/init.c index 1a25dec661..482821aacc 100644 --- a/testsuites/fstests/fsimfsgeneric01/init.c +++ b/testsuites/fstests/fsimfsgeneric01/init.c @@ -46,8 +46,6 @@ typedef enum { TEST_DESTROYED } test_state; -static test_state global_state = TEST_NEW; - static int handler_open( rtems_libio_t *iop, const char *path, @@ -263,6 +261,7 @@ static const IMFS_node_control node_control = { static void test_imfs_make_generic_node(void) { + test_state state = TEST_NEW; int rv = 0; int fd = 0; const char *path = "generic"; @@ -274,7 +273,7 @@ static void test_imfs_make_generic_node(void) path, S_IFCHR | S_IRWXU | S_IRWXG | S_IRWXO, &node_control, - &global_state + &state ); rtems_test_assert(rv == 0); @@ -311,7 +310,7 @@ static void test_imfs_make_generic_node(void) rv = unlink(path); rtems_test_assert(rv == 0); - rtems_test_assert(global_state == TEST_DESTROYED); + rtems_test_assert(state == TEST_DESTROYED); } static const IMFS_node_control node_invalid_control = { |