diff options
author | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2009-09-16 13:22:01 +0000 |
---|---|---|
committer | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2009-09-16 13:22:01 +0000 |
commit | 61dc7dc2a3f9fd8233020c65bde6460f458d93d9 (patch) | |
tree | f4c85a85d25a030a196aa454250d9f4d3e7c8701 /nuttx | |
parent | 6ea8fe291f358e9c857a1b5f1170e20004ca0532 (diff) | |
download | px4-nuttx-61dc7dc2a3f9fd8233020c65bde6460f458d93d9.tar.gz px4-nuttx-61dc7dc2a3f9fd8233020c65bde6460f458d93d9.tar.bz2 px4-nuttx-61dc7dc2a3f9fd8233020c65bde6460f458d93d9.zip |
remove warning
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@2060 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx')
-rw-r--r-- | nuttx/lib/lib_fclose.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/nuttx/lib/lib_fclose.c b/nuttx/lib/lib_fclose.c index b45a2a8f1..1c791ea21 100644 --- a/nuttx/lib/lib_fclose.c +++ b/nuttx/lib/lib_fclose.c @@ -1,7 +1,7 @@ /**************************************************************************** * lib/lib_fclose.c * - * Copyright (C) 2007, 2008 Gregory Nutt. All rights reserved. + * Copyright (C) 2007-2009 Gregory Nutt. All rights reserved. * Author: Gregory Nutt <spudmonkey@racsa.co.cr> * * Redistribution and use in source and binary forms, with or without @@ -62,14 +62,14 @@ int fclose(FAR FILE *stream) { ret = close(stream->fs_filedes); } -#ifdef CONFIG_CPP_HAVE_WARNING -# warning REVIEW for race conditions -#endif + #if CONFIG_STDIO_BUFFER_SIZE > 0 /* Destroy the semaphore */ + sem_destroy(&stream->fs_sem); /* release the buffer */ + if (stream->fs_bufstart) { free(stream->fs_bufstart); @@ -92,6 +92,7 @@ int fclose(FAR FILE *stream) stream->fs_filedes = -1; } + return ret; } |