- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: class issue
Operating System - HP-UX
1748180
Members
4058
Online
108759
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
Discussions
Discussions
Forums
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
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Go to solution
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
тАО12-09-2004 04:18 AM
тАО12-09-2004 04:18 AM
Good Morning:
I have a program in c++ calling a function in OCI oracle (olog). When I call the function from main() conenction made by olog is successfull, but if I try to do the same call from a function member of a class, the olog produce a Memory Fault (coredump) error:
root # ./demo2
Just Before olog
Yes Connected from main()
Just Before olog
sh: 19337 Memory fault(coredump)
The core shows error in a library in Oracle, but this library is stripped, so I can not get any clues. I am attaching the main programm, the class used and the result of gdb. One of you guys could give me any idea how to fix that please. Thanks in advance.
I am attaching
I have a program in c++ calling a function in OCI oracle (olog). When I call the function from main() conenction made by olog is successfull, but if I try to do the same call from a function member of a class, the olog produce a Memory Fault (coredump) error:
root # ./demo2
Just Before olog
Yes Connected from main()
Just Before olog
sh: 19337 Memory fault(coredump)
The core shows error in a library in Oracle, but this library is stripped, so I can not get any clues. I am attaching the main programm, the class used and the result of gdb. One of you guys could give me any idea how to fix that please. Thanks in advance.
I am attaching
alfonsoarias
Solved! Go to Solution.
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-09-2004 04:43 AM
- Tags:
- memset
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-09-2004 04:51 AM
тАО12-09-2004 04:51 AM
Re: class issue
Thanks Clay, i change that statement. But still going to Memory Fault in the class execution. Do you note other thing in the code or in the gdb result?
Thanks
Thanks
alfonsoarias
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-09-2004 10:06 AM
тАО12-09-2004 10:06 AM
Re: class issue
Okay, I copied your source and split out the header file. I reproduced your error and made these changes in both main and inside your class and all was well.
ub4 hda[HDA_SIZE/sizeof(ub4)];
change to:
ub4 hda[HDA_SIZE];
--------------------------------------
memset(hda,'\0',HDA_SIZE/sizeof(ub4));
change to:
memset((void *) hda,(int) '\0',sizeof(hda));
After doing this I saw your "Yes Connected from main()" and your "Yes Connected from class" probes. And what is this printf stuff doing in C++; it ought to be cout.
ub4 hda[HDA_SIZE/sizeof(ub4)];
change to:
ub4 hda[HDA_SIZE];
--------------------------------------
memset(hda,'\0',HDA_SIZE/sizeof(ub4));
change to:
memset((void *) hda,(int) '\0',sizeof(hda));
After doing this I saw your "Yes Connected from main()" and your "Yes Connected from class" probes. And what is this printf stuff doing in C++; it ought to be cout.
If it ain't broke, I can fix that.
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.
News and Events
Support
© Copyright 2024 Hewlett Packard Enterprise Development LP