Closed
Bug 726785
Opened 14 years ago
Closed 2 years ago
NSS Memory Leak
Categories
(NSS :: Libraries, defect, P5)
Tracking
(Not tracked)
RESOLVED
INACTIVE
People
(Reporter: vinuthomas.goa, Unassigned)
Details
User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; InfoPath.1; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; .NET4.0C; .NET4.0E)
Steps to reproduce:
We are using NSPR and NSS for SSL communication.
This whole NSPR and NSS functionality is encapsulated in a dll on a windows box.
We use PR_Init and NSS_Init to initialize the library apart from other calls.
We then create a PR_NewTCPSocket() to create a socket and then set SSL options on it.
Then we do PR_Read(to read on the socket) and PR_Write(to write on the socket).
Now when this library is used from multiple threads simulateneously there is a constant memory leak. From one thread with many iterations, i havent observed a significant leak. But from multiple threads, i have observed a leak.
I have observed this leak with nspr-4.1.2/nss-3.3.2 and also with nspr-4.6.4/nss-3.11.4.
Also the way we use the library seems to create/use Fibers on windows. I dont know why this is the case.
Has anybody faced similar memory leak issues and if so, is there a fix.
Actual results:
memory is leaking
Expected results:
memory should not be leaking
Comment 1•14 years ago
|
||
The use of fibers on Windows indicates that you are not building with OS_TARGET=WIN95. All Mozilla applications use NSPR built with OS_TARGET=WIN95. It is possible that you are seeing a leak that we normally don't see, because of some bug in the OS_TARGET=WINNT (which is the the default) configuration of NSPR. You should try to build with OS_TARGET=WIN95 and report back whether that worked around your problem. This would be very helpful information.
I am trying to build NSPR/NSS with OS_TARGET=WIN95.
I installed Mozialla Build Tools and also Netscape wintools(because without this gmake doesnt work).
But the build if just failing for me.
The last error i get is
cd ../../nsprpub/WIN954.0_OPT.OBJ ; c:/MozTools/bin/gmake.exe
c:\MozTools\bin\gmake.exe[1]: Entering directory `c:/NSPR_NSS/nss-3.11.4-with-ns
pr-4.6.4.tar/nss-3.11.4/mozilla/nsprpub/WIN954.0_OPT.OBJ'
cd config; c:/MozTools/bin/gmake.exe -j1 export
c:\MozTools\bin\gmake.exe[2]: Entering directory `c:/NSPR_NSS/nss-3.11.4-with-ns
pr-4.6.4.tar/nss-3.11.4/mozilla/nsprpub/WIN954.0_OPT.OBJ/config'
cl -Fonow.obj -c -W3 -nologo -GF -Gy -MD -O2 -UDEBUG -U_DEBUG -UWINNT -D
NDEBUG=1 -DXP_PC=1 -DWIN32=1 -DWIN95=1 -D_PR_GLOBAL_THREADS_ONLY=1 -D_X86_=1 -D
FORCE_PR_LOG /c/NSPR_NSS/nss-3.11.4-with-nspr-4.6.4.tar/nss-3.11.4/mozilla/nsp
rpub/WIN954.0_OPT.OBJ/config/../../config/now.c
cl : Command line warning D9002 : ignoring unknown option '/c/NSPR_NSS/nss-3.11.
4-with-nspr-4.6.4.tar/nss-3.11.4/mozilla/nsprpub/WIN954.0_OPT.OBJ/config/../../c
onfig/now.c'
cl : Command line error D8003 : missing source filename
c:\MozTools\bin\gmake.exe[2]: *** [now.obj] Error 2
c:\MozTools\bin\gmake.exe[2]: Leaving directory `c:/NSPR_NSS/nss-3.11.4-with-nsp
r-4.6.4.tar/nss-3.11.4/mozilla/nsprpub/WIN954.0_OPT.OBJ/config'
c:\MozTools\bin\gmake.exe[1]: *** [export] Error 2
c:\MozTools\bin\gmake.exe[1]: Leaving directory `c:/NSPR_NSS/nss-3.11.4-with-nsp
r-4.6.4.tar/nss-3.11.4/mozilla/nsprpub/WIN954.0_OPT.OBJ'
c:\MozTools\bin\gmake.exe: *** [build_nspr] Error 2
This file now.c infact exists. So i dont understand why it says "missing source filename". Can anyone through some insight into this.
I used "make nss_build_all" and it builds fine for me. gmake just doesnt work.
But the problem is in dist/WIN954.0_OPT.OBJ/include folder i dont see the nss include files. I only see the nspr include files. So I am not able to compile my application.
Can anyone throw some light why the nss include files are not copied to dist.
Updated•3 years ago
|
Severity: normal → S3
Updated•2 years ago
|
Severity: S3 → S4
Status: UNCONFIRMED → RESOLVED
Closed: 2 years ago
Priority: -- → P5
Resolution: --- → INACTIVE
You need to log in
before you can comment on or make changes to this bug.
Description
•