Changeset 1583
- Timestamp:
- Oct 13, 2004, 5:08:24 AM (21 years ago)
- Location:
- trunk/src/emx/src/lib/io
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/emx/src/lib/io/_fopen.c
-
Property cvs2svn:cvs-rev
changed from
1.6
to1.7
r1582 r1583 35 35 default: 36 36 errno = EINVAL; 37 STREAMV_LOCK; 37 38 _closestream (dst); 39 STREAMV_UNLOCK; 38 40 return NULL; 39 41 } … … 81 83 if (_fmutex_create (&dst->__u.__fsem, 0) != 0) 82 84 { 85 STREAMV_LOCK; 83 86 _closestream (dst); 87 STREAMV_UNLOCK; 84 88 return NULL; 85 89 } … … 87 91 if (dst->_handle < 0) 88 92 { 93 STREAMV_LOCK; 89 94 _closestream (dst); 95 STREAMV_UNLOCK; 90 96 return NULL; 91 97 } -
Property cvs2svn:cvs-rev
changed from
-
trunk/src/emx/src/lib/io/_mfopen.c
-
Property cvs2svn:cvs-rev
changed from
1.4
to1.5
r1582 r1583 74 74 { 75 75 errno = ENOMEM; 76 STREAMV_LOCK; 76 77 _closestream (stream); 78 STREAMV_UNLOCK; 77 79 return NULL; 78 80 } … … 109 111 110 112 buf = stream->_buffer; 113 STREAMV_LOCK; 111 114 _closestream (stream); 115 STREAMV_UNLOCK; 112 116 return buf; 113 117 } -
Property cvs2svn:cvs-rev
changed from
-
trunk/src/emx/src/lib/io/_newstre.c
-
Property cvs2svn:cvs-rev
changed from
1.8
to1.9
r1582 r1583 109 109 110 110 if (stream->__pSV) 111 {112 STREAMV_LOCK;113 111 ((struct streamvec *)stream->__pSV)->cFree++; 114 STREAMV_UNLOCK;115 }116 112 } -
Property cvs2svn:cvs-rev
changed from
-
trunk/src/emx/src/lib/io/fclose.c
-
Property cvs2svn:cvs-rev
changed from
1.2
to1.3
r1582 r1583 6 6 #include <string.h> 7 7 #include <io.h> 8 #include <386/builtin.h> 9 #include <sys/fmutex.h> 8 10 #include <emx/io.h> 9 11 … … 30 32 free (stream->_buffer); 31 33 } 34 STREAMV_LOCK; 32 35 _closestream (stream); 36 STREAMV_UNLOCK; 33 37 return result; 34 38 } -
Property cvs2svn:cvs-rev
changed from
-
trunk/src/emx/src/lib/io/fdopen.c
-
Property cvs2svn:cvs-rev
changed from
1.7
to1.8
r1582 r1583 32 32 if (_fmutex_create (&dst->__u.__fsem, 0) != 0) 33 33 { 34 STREAMV_LOCK; 34 35 _closestream (dst); 36 STREAMV_UNLOCK; 35 37 return NULL; 36 38 } … … 47 49 break; 48 50 default: 51 STREAMV_LOCK; 49 52 _closestream (dst); 53 STREAMV_UNLOCK; 50 54 return NULL; 51 55 } -
Property cvs2svn:cvs-rev
changed from
-
trunk/src/emx/src/lib/io/freopen.c
-
Property cvs2svn:cvs-rev
changed from
1.3
to1.4
r1582 r1583 14 14 STREAMV_LOCK; 15 15 if (stream->_flags & _IOOPEN) 16 fclose (stream); 16 { /* duplication of fclose(), but no _closestream lock. */ 17 int result; 18 char buf[L_tmpnam]; 19 20 result = EOF; 21 if ((stream->_flags & _IOOPEN) && !(stream->_flags & _IOSPECIAL)) 22 { 23 result = 0; 24 result = fflush (stream); 25 if (close (stream->_handle) < 0) 26 result = EOF; 27 if (result == 0 && (stream->_flags & _IOTMP)) 28 { 29 _itoa (stream->_tmpidx, buf, 10); 30 strcat (buf, ".tmp"); 31 if (remove (buf) != 0) 32 result = EOF; 33 } 34 if ((stream->_flags & _IOBUFMASK) == _IOBUFLIB) 35 free (stream->_buffer); 36 } 37 _closestream (stream); 38 } 17 39 result = _openstream (stream, fname, mode, SH_DENYNO, 0); 18 40 STREAMV_UNLOCK; -
Property cvs2svn:cvs-rev
changed from
Note:
See TracChangeset
for help on using the changeset viewer.