Changeset 101869 in vbox for trunk/src/libs/xpcom18a4/nsprpub/pr/include/private
- Timestamp:
- Nov 6, 2023 1:38:17 PM (15 months ago)
- Location:
- trunk/src/libs/xpcom18a4/nsprpub/pr/include/private
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/libs/xpcom18a4/nsprpub/pr/include/private/pprio.h
r11551 r101869 151 151 */ 152 152 153 #ifdef WIN32154 155 #define PR_SOCK_STREAM 1156 #define PR_SOCK_DGRAM 2157 158 #else /* WIN32 */159 160 153 #define PR_SOCK_STREAM SOCK_STREAM 161 154 #define PR_SOCK_DGRAM SOCK_DGRAM 162 163 #endif /* WIN32 */164 155 165 156 /* … … 211 202 PRTransmitFileFlags flags, PRIntervalTime timeout); 212 203 213 #ifdef WIN32214 /* FUNCTION: PR_NTFast_AcceptRead215 ** DESCRIPTION:216 ** NT has the notion of an "accept context", which is only needed in217 ** order to make certain calls. By default, a socket connected via218 ** AcceptEx can only do a limited number of things without updating219 ** the acceptcontext. The generic version of PR_AcceptRead always220 ** updates the accept context. This version does not.221 **/222 NSPR_API(PRInt32) PR_NTFast_AcceptRead(PRFileDesc *sd, PRFileDesc **nd,223 PRNetAddr **raddr, void *buf, PRInt32 amount, PRIntervalTime t);224 225 typedef void (*_PR_AcceptTimeoutCallback)(void *);226 227 /* FUNCTION: PR_NTFast_AcceptRead_WithTimeoutCallback228 ** DESCRIPTION:229 ** The AcceptEx call combines the accept with the read function. However,230 ** our daemon threads need to be able to wakeup and reliably flush their231 ** log buffers if the Accept times out. However, with the current blocking232 ** interface to AcceptRead, there is no way for us to timeout the Accept;233 ** this is because when we timeout the Read, we can close the newly234 ** socket and continue; but when we timeout the accept itself, there is no235 ** new socket to timeout. So instead, this version of the function is236 ** provided. After the initial timeout period elapses on the accept()237 ** portion of the function, it will call the callback routine and then238 ** continue the accept. If the timeout occurs on the read, it will239 ** close the connection and return error.240 */241 NSPR_API(PRInt32) PR_NTFast_AcceptRead_WithTimeoutCallback(242 PRFileDesc *sd,243 PRFileDesc **nd,244 PRNetAddr **raddr,245 void *buf,246 PRInt32 amount,247 PRIntervalTime t,248 _PR_AcceptTimeoutCallback callback,249 void *callback_arg);250 251 /* FUNCTION: PR_NTFast_Accept252 ** DESCRIPTION:253 ** NT has the notion of an "accept context", which is only needed in254 ** order to make certain calls. By default, a socket connected via255 ** AcceptEx can only do a limited number of things without updating256 ** the acceptcontext. The generic version of PR_Accept always257 ** updates the accept context. This version does not.258 **/259 NSPR_API(PRFileDesc*) PR_NTFast_Accept(PRFileDesc *fd, PRNetAddr *addr,260 PRIntervalTime timeout);261 262 /* FUNCTION: PR_NTFast_Update263 ** DESCRIPTION:264 ** For sockets accepted with PR_NTFast_Accept or PR_NTFastAcceptRead,265 ** this function will update the accept context for those sockets,266 ** so that the socket can make general purpose socket calls.267 ** Without calling this, the only operations supported on the socket268 ** Are PR_Read, PR_Write, PR_Transmitfile, and PR_Close.269 */270 NSPR_API(void) PR_NTFast_UpdateAcceptContext(PRFileDesc *acceptSock,271 PRFileDesc *listenSock);272 273 274 /* FUNCTION: PR_NT_CancelIo275 ** DESCRIPTION:276 ** Cancel IO operations on fd.277 */278 NSPR_API(PRStatus) PR_NT_CancelIo(PRFileDesc *fd);279 280 281 #endif /* WIN32 */282 283 /*284 ** Need external access to this on Mac so we can first set up our faux285 ** environment vars286 */287 #ifdef XP_MAC288 NSPR_API(void) PR_Init_Log(void);289 #endif290 291 292 204 PR_END_EXTERN_C 293 205 -
trunk/src/libs/xpcom18a4/nsprpub/pr/include/private/primpl.h
r101843 r101869 54 54 typedef struct PRSegment PRSegment; 55 55 56 #ifdef XP_MAC57 #include "prosdep.h"58 #include "probslet.h"59 #else60 56 #include "md/prosdep.h" 61 57 #include "obsolete/probslet.h" 62 #endif /* XP_MAC */63 58 64 59 #ifdef _PR_HAVE_POSIX_SEMAPHORES … … 748 743 #define _PR_MD_QUERY_FD_INHERITABLE _MD_QUERY_FD_INHERITABLE 749 744 750 #ifdef XP_BEOS751 752 extern PRLock *_connectLock;753 754 typedef struct _ConnectListNode {755 PRInt32 osfd;756 PRNetAddr addr;757 PRUint32 addrlen;758 PRIntervalTime timeout;759 } ConnectListNode;760 761 extern ConnectListNode connectList[64];762 763 extern PRUint32 connectCount;764 765 #endif /* XP_BEOS */766 767 745 PR_END_EXTERN_C 768 746 -
trunk/src/libs/xpcom18a4/nsprpub/pr/include/private/prpriv.h
r1 r101869 43 43 */ 44 44 45 #ifndef XP_MAC46 45 #include "private/pprio.h" 47 46 #include "private/pprthred.h" 48 #else 49 #include "pprio.h" 50 #include "pprthred.h" 51 #endif 47 52 48 53 49 #endif /* prpriv_h___ */
Note:
See TracChangeset
for help on using the changeset viewer.