summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authordeischen <deischen@FreeBSD.org>2001-02-11 22:04:18 +0000
committerdeischen <deischen@FreeBSD.org>2001-02-11 22:04:18 +0000
commitd5657ce8b69e343a4dda07786bb158c464f9b4d6 (patch)
tree3d31e29f4a00d4ba3eefbcfc0b9a36d5afc6d64f /include
parentfcd1a54dca5be37dd1cafbdbab2f97f6405cadc8 (diff)
downloadFreeBSD-src-d5657ce8b69e343a4dda07786bb158c464f9b4d6.zip
FreeBSD-src-d5657ce8b69e343a4dda07786bb158c464f9b4d6.tar.gz
libc MT-safety, part 2.
Add a lock to FILE and define an additional flag.
Diffstat (limited to 'include')
-rw-r--r--include/stdio.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/stdio.h b/include/stdio.h
index 2957a8b..3b1edaa 100644
--- a/include/stdio.h
+++ b/include/stdio.h
@@ -68,6 +68,8 @@ struct __sbuf {
int _size;
};
+struct __file_lock;
+
/*
* stdio state variables.
*
@@ -125,6 +127,7 @@ typedef struct __sFILE {
/* Unix stdio files get aligned to block boundaries on fseek() */
int _blksize; /* stat.st_blksize (may be != _bf._size) */
fpos_t _offset; /* current lseek offset (see WARNING) */
+ struct __file_lock *_lock; /* used for MT-safety */
} FILE;
__BEGIN_DECLS
@@ -147,6 +150,7 @@ __END_DECLS
#define __SOFF 0x1000 /* set iff _offset is in fact correct */
#define __SMOD 0x2000 /* true => fgetln modified _p text */
#define __SALC 0x4000 /* allocate string space dynamically */
+#define __SIGN 0x8000 /* ignore this file in _fwalk */
/*
* The following three definitions are for ANSI C, which took them
OpenPOWER on IntegriCloud