aboutsummaryrefslogtreecommitdiffhomepage
path: root/mimedb.cpp
diff options
context:
space:
mode:
authorGravatar Peter Ammon <corydoras@ridiculousfish.com>2012-03-02 00:27:40 -0800
committerGravatar Peter Ammon <corydoras@ridiculousfish.com>2012-03-02 00:27:40 -0800
commit8b26d0104c1d85c271e5ce6e08bfe64a779beba7 (patch)
tree995568526f190084fd12d74bc6dcd0e828b1018a /mimedb.cpp
parent36622c35781c3212c2102c45781a496f3e1b3659 (diff)
Some initial changes to use CLO_EXEC, with an eye towards some day using it correctly.
Diffstat (limited to 'mimedb.cpp')
-rw-r--r--mimedb.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/mimedb.cpp b/mimedb.cpp
index 2639013f..43681b36 100644
--- a/mimedb.cpp
+++ b/mimedb.cpp
@@ -196,6 +196,7 @@ char *my_strdup( const char *s )
*/
static const char * search_ini( const char *filename, const char *match )
{
+ /* OK to not use CLO_EXEC here because mimedb is single threaded */
FILE *f = fopen( filename, "r" );
char buf[4096];
int len=strlen(match);
@@ -584,6 +585,7 @@ static char *get_description( const char *mimetype )
return 0;
}
+ /* OK to not use CLO_EXEC here because mimedb is single threaded */
fd = open( fn.c_str(), O_RDONLY );
// fprintf( stderr, "%s\n", fn );