Hi,
I have some C++ code which does the following
retcode = SQLFreeStmt(hStmt,SQL_UNBIND);
retcode = SQLFreeStmt(hStmt,SQL_RESET_PARAMS);
retcode = SQLFreeStmt(hStmt,SQL_CLOSE);
But sometimes it cores in the third statement.
I tried using "SQLCloseCursor (hStmt)" in its place but it also core dumped
sometimes.
Following is the stack
signal SEGV (no mapping at the fault address) in
Or8Statement::setToAllocatedSte at 0xfd1be710
0xfd1be710: setToAllocatedState+0x0368: ld [%o0 + 0xc], %g2
SQLCloseCursor(0x3114d68, 0xffffffff, 0x2fb58d8, 0x4e3f24, 0x45c0b4, 0x2)
BaseStatement::SQLCloseCursor(0x303c8b0, 0xffffffff, 0x0, 0xc, 0x5c,
0xff1f1d14)
BaseStatement::resetToAllocated(0x303c8b0, 0x0, 0x0, 0x8, 0x8, 0x8)
Or8Statement::setToAllocatedState(0x303c8b0, 0x28, 0x8, 0x0, 0x0, 0x0)
The contents of hStmt were same in all three statements at the time of core.
and the return value was 0 in all cases.
Can anybody tell me what could be wrong.