HPE GreenLake Administration
- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- malloc in thread
Operating System - HP-UX
1832302
Members
2158
Online
110041
Solutions
Forums
Categories
Company
Local Language
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
back
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-01-2001 06:43 PM
03-01-2001 06:43 PM
malloc in thread
Hi.
I hit a code dump problem in one of my running thread. In that thread function, I call some odbc function and hit the core dump when the odbc function try to allocate memory by using malloc. The stacktrace is sth. like:
#0 0x75f450c8 in mallinfo () from /usr/lib/libc.2
#1 0x75f41ccc in malloc () from /usr/lib/libc.2
#2 0x75f29c7c in calloc () from /usr/lib/libc.2
#3 0x74b6c5f4 in nsbal ()
from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#4 0x74b2e018 in nsprecv ()
from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#5 0x74bad560 in nscon ()
from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#6 0x74b6f1b0 in nsdo () from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#7 0x74bac90c in nscall3 ()
from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#8 0x74babb10 in nscall ()
from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#9 0x74b7fe8c in niotns ()
from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#10 0x74b351e0 in nigcall ()
from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#11 0x74b15338 in osncon ()
from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#12 0x74a57190 in upiini ()
from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#13 0x74a46b98 in upiah0 ()
from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#14 0x74a20554 in kpuatch ()
from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#15 0x74a3a1f8 in OCIServerAttach ()
from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#16 0x75028120 in ?? () from /local1/odbc/3.60/lib/ivor815.sl
#17 0x7471776c in ?? () from /local1/odbc/3.60/lib/libivbas15.sl
#18 0x74714c3c in ?? () from /local1/odbc/3.60/lib/libivbas15.sl
Error accessing memory address 0x0: Invalid argument.
My explanation is that: the malloc() call in the working thread is not allocating memory from heap instead from the thread stack?
Can you HP-UX expert explan to me?
Thanks a lot!
--ye
I hit a code dump problem in one of my running thread. In that thread function, I call some odbc function and hit the core dump when the odbc function try to allocate memory by using malloc. The stacktrace is sth. like:
#0 0x75f450c8 in mallinfo () from /usr/lib/libc.2
#1 0x75f41ccc in malloc () from /usr/lib/libc.2
#2 0x75f29c7c in calloc () from /usr/lib/libc.2
#3 0x74b6c5f4 in nsbal ()
from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#4 0x74b2e018 in nsprecv ()
from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#5 0x74bad560 in nscon ()
from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#6 0x74b6f1b0 in nsdo () from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#7 0x74bac90c in nscall3 ()
from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#8 0x74babb10 in nscall ()
from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#9 0x74b7fe8c in niotns ()
from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#10 0x74b351e0 in nigcall ()
from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#11 0x74b15338 in osncon ()
from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#12 0x74a57190 in upiini ()
from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#13 0x74a46b98 in upiah0 ()
from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#14 0x74a20554 in kpuatch ()
from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#15 0x74a3a1f8 in OCIServerAttach ()
from /local/app/oracle/product/8.1.5/lib/libclntsh.sl
#16 0x75028120 in ?? () from /local1/odbc/3.60/lib/ivor815.sl
#17 0x7471776c in ?? () from /local1/odbc/3.60/lib/libivbas15.sl
#18 0x74714c3c in ?? () from /local1/odbc/3.60/lib/libivbas15.sl
Error accessing memory address 0x0: Invalid argument.
My explanation is that: the malloc() call in the working thread is not allocating memory from heap instead from the thread stack?
Can you HP-UX expert explan to me?
Thanks a lot!
--ye
2 REPLIES 2
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-01-2007 12:19 PM
09-01-2007 12:19 PM
Re: malloc in thread
A signal in malloc is usually an indication of heap corruption.
>in the working thread
The stack trace didn't go all the way back but if this is in a thread, it could be a thread stack overflow.
>in the working thread
The stack trace didn't go all the way back but if this is in a thread, it could be a thread stack overflow.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-02-2007 08:41 PM
09-02-2007 08:41 PM
Re: malloc in thread
Hi,
In more than 99% of cases you corrupted the heap head.
in 50% of the case it is when you malloc() a string of 1 byte less what it is needed, usually malloc(strlen(mystring)) when it should be malloc(strlen(mystring)+1)
In more than 99% of cases you corrupted the heap head.
in 50% of the case it is when you malloc() a string of 1 byte less what it is needed, usually malloc(strlen(mystring)) when it should be malloc(strlen(mystring)+1)
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
Company
Events and news
Customer resources
© Copyright 2025 Hewlett Packard Enterprise Development LP