зеркало из https://github.com/mozilla/gecko-dev.git
Bug 865828: Update NSPR to NSPR_4_10_BETA2. r=wtc.
Includes fixes for bug 844513, bug 331169, bug 859066, and bug 871064.
This commit is contained in:
Родитель
a572f71b43
Коммит
a8673594b7
|
@ -1 +1 @@
|
|||
NSPR_4_10_BETA1
|
||||
NSPR_4_10_BETA2
|
||||
|
|
|
@ -10,3 +10,4 @@
|
|||
*/
|
||||
|
||||
#error "Do not include this header file."
|
||||
|
||||
|
|
|
@ -157,7 +157,6 @@ PR_IMPLEMENT(void *) PL_ArenaAllocate(PLArenaPool *pool, PRUint32 nb)
|
|||
pool->current = a;
|
||||
rp = (char *)a->avail;
|
||||
a->avail += nb;
|
||||
PL_MAKE_MEM_UNDEFINED(rp, nb);
|
||||
return rp;
|
||||
}
|
||||
} while( NULL != (a = a->next) );
|
||||
|
@ -188,7 +187,6 @@ PR_IMPLEMENT(void *) PL_ArenaAllocate(PLArenaPool *pool, PRUint32 nb)
|
|||
pool->current = a;
|
||||
if ( NULL == pool->first.next )
|
||||
pool->first.next = a;
|
||||
PL_MAKE_MEM_UNDEFINED(rp, nb);
|
||||
return(rp);
|
||||
}
|
||||
}
|
||||
|
@ -215,7 +213,6 @@ PR_IMPLEMENT(void *) PL_ArenaAllocate(PLArenaPool *pool, PRUint32 nb)
|
|||
pool->first.next = a;
|
||||
PL_COUNT_ARENA(pool,++);
|
||||
COUNT(pool, nmallocs);
|
||||
PL_MAKE_MEM_UNDEFINED(rp, nb);
|
||||
return(rp);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -143,10 +143,10 @@ void __asan_unpoison_memory_region(void const volatile *addr, size_t size);
|
|||
if (_q > _a->limit) { \
|
||||
_p = (PRUword)PL_ArenaAllocate(pool, _nb); \
|
||||
} else { \
|
||||
PL_MAKE_MEM_UNDEFINED((void *)_p, nb); \
|
||||
_a->avail = _q; \
|
||||
} \
|
||||
p = (void *)_p; \
|
||||
PL_MAKE_MEM_UNDEFINED(p, nb); \
|
||||
PL_ArenaCountAllocation(pool, nb); \
|
||||
PR_END_MACRO
|
||||
|
||||
|
@ -158,7 +158,7 @@ void __asan_unpoison_memory_region(void const volatile *addr, size_t size);
|
|||
PRUword _q = _p + _incr; \
|
||||
if (_p == (PRUword)(p) + PL_ARENA_ALIGN(pool, size) && \
|
||||
_q <= _a->limit) { \
|
||||
PL_MAKE_MEM_UNDEFINED((void *)((PRUword)(p) + size), incr); \
|
||||
PL_MAKE_MEM_UNDEFINED((unsigned char *)(p) + size, incr); \
|
||||
_a->avail = _q; \
|
||||
PL_ArenaCountInplaceGrowth(pool, size, incr); \
|
||||
} else { \
|
||||
|
|
|
@ -47,6 +47,9 @@ PR_EXTERN(void) PL_CompactArenaPool(PLArenaPool *pool);
|
|||
|
||||
/*
|
||||
** Friend functions used by the PL_ARENA_*() macros.
|
||||
**
|
||||
** WARNING: do not call these functions directly. Always use the
|
||||
** PL_ARENA_*() macros.
|
||||
**/
|
||||
PR_EXTERN(void *) PL_ArenaAllocate(PLArenaPool *pool, PRUint32 nb);
|
||||
|
||||
|
|
|
@ -288,14 +288,6 @@ static PRStatus PR_CALLBACK SocketConnectContinue(
|
|||
|
||||
#elif defined(WIN32) || defined(WIN16)
|
||||
|
||||
#if defined(WIN32)
|
||||
/*
|
||||
* The sleep circumvents a bug in Win32 WinSock.
|
||||
* See Microsoft Knowledge Base article ID: Q165989.
|
||||
*/
|
||||
Sleep(0);
|
||||
#endif /* WIN32 */
|
||||
|
||||
if (out_flags & PR_POLL_EXCEPT) {
|
||||
int len = sizeof(err);
|
||||
if (getsockopt(osfd, (int)SOL_SOCKET, SO_ERROR, (char *) &err, &len)
|
||||
|
|
|
@ -2263,7 +2263,7 @@ static PRStatus pr_NetAddrToStringGNI(
|
|||
md_af = AF_INET6;
|
||||
#ifndef _PR_HAVE_SOCKADDR_LEN
|
||||
addrcopy = *addr;
|
||||
addrcopy.raw.family = AF_INET6;
|
||||
addrcopy.raw.family = md_af;
|
||||
addrp = &addrcopy;
|
||||
#endif
|
||||
}
|
||||
|
|
|
@ -715,7 +715,8 @@ PR_IMPLEMENT(void) PR_SetThreadPriority(PRThread *thred, PRThreadPriority newPri
|
|||
* because adjusting the nice value might be permitted for certain
|
||||
* ranges but not for others. */
|
||||
PR_LOG(_pr_thread_lm, PR_LOG_MIN,
|
||||
("PR_SetThreadPriority: no thread scheduling privilege"));
|
||||
("PR_SetThreadPriority: setpriority failed with error %d",
|
||||
errno));
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
@ -890,6 +891,8 @@ void _PR_InitThreads(
|
|||
int rv;
|
||||
PRThread *thred;
|
||||
|
||||
PR_ASSERT(priority == PR_PRIORITY_NORMAL);
|
||||
|
||||
#ifdef _PR_NEED_PTHREAD_INIT
|
||||
/*
|
||||
* On BSD/OS (3.1 and 4.0), the pthread subsystem is lazily
|
||||
|
@ -979,7 +982,6 @@ void _PR_InitThreads(
|
|||
PR_ASSERT(0 == rv);
|
||||
rv = pthread_setspecific(pt_book.key, thred);
|
||||
PR_ASSERT(0 == rv);
|
||||
PR_SetThreadPriority(thred, priority);
|
||||
} /* _PR_InitThreads */
|
||||
|
||||
#ifdef __GNUC__
|
||||
|
|
|
@ -65,6 +65,8 @@ void _PR_InitThreads(PRThreadType type, PRThreadPriority priority,
|
|||
PRThread *thread;
|
||||
PRThreadStack *stack;
|
||||
|
||||
PR_ASSERT(priority == PR_PRIORITY_NORMAL);
|
||||
|
||||
_pr_terminationCVLock = PR_NewLock();
|
||||
_pr_activeLock = PR_NewLock();
|
||||
|
||||
|
|
|
@ -10,3 +10,4 @@
|
|||
*/
|
||||
|
||||
#error "Do not include this header file."
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче