summaryrefslogtreecommitdiff
path: root/apps/examples/ostest/sighand.c
diff options
context:
space:
mode:
authorpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2011-05-28 21:42:18 +0000
committerpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2011-05-28 21:42:18 +0000
commit94c7babe23d72a1e379da0cf0aab32fcf9fadcf3 (patch)
treeeedc930a4ed4a1108c87cae26d3fcda7e411dd1f /apps/examples/ostest/sighand.c
parent405c2b328ff4cd571bb9e464541b4d297b18f93d (diff)
downloadnuttx-94c7babe23d72a1e379da0cf0aab32fcf9fadcf3.tar.gz
nuttx-94c7babe23d72a1e379da0cf0aab32fcf9fadcf3.tar.bz2
nuttx-94c7babe23d72a1e379da0cf0aab32fcf9fadcf3.zip
atexit() functions now called when task killed by task delete; For MCUs with <= 64Kb of SRAM, CONFIG_MM_SMALL can be defined to reduce the memory allocation overhead
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@3648 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'apps/examples/ostest/sighand.c')
-rw-r--r--apps/examples/ostest/sighand.c22
1 files changed, 5 insertions, 17 deletions
diff --git a/apps/examples/ostest/sighand.c b/apps/examples/ostest/sighand.c
index 66f98cb58..681531639 100644
--- a/apps/examples/ostest/sighand.c
+++ b/apps/examples/ostest/sighand.c
@@ -152,10 +152,7 @@ static int waiter_main(int argc, char *argv[])
/* Take the semaphore */
printf("waiter_main: Waiting on semaphore\n" );
-
-#if CONFIG_NFILE_STREAMS > 0
- fflush(stdout);
-#endif
+ FFLUSH();
status = sem_wait(&sem);
if (status != 0)
@@ -181,10 +178,7 @@ static int waiter_main(int argc, char *argv[])
status = sigaction(WAKEUP_SIGNAL, &act, &oact);
printf("waiter_main: done\n" );
-
-#if CONFIG_NFILE_STREAMS > 0
- fflush(stdout);
-#endif
+ FFLUSH();
threadexited = true;
return 0;
@@ -231,9 +225,7 @@ void sighand_test(void)
/* Wait a bit */
-#if CONFIG_NFILE_STREAMS > 0
- fflush(stdout);
-#endif
+ FFLUSH();
sleep(2);
/* Then signal the waiter thread. */
@@ -255,9 +247,7 @@ void sighand_test(void)
/* Wait a bit */
-#if CONFIG_NFILE_STREAMS > 0
- fflush(stdout);
-#endif
+ FFLUSH();
sleep(2);
/* Then check the result */
@@ -273,7 +263,5 @@ void sighand_test(void)
}
printf("sighand_test: done\n" );
-#if CONFIG_NFILE_STREAMS > 0
- fflush(stdout);
-#endif
+ FFLUSH();
}