Skip to content

dpiConn_close crash #200

@unficyp

Description

@unficyp
  1. What version of ODPI-C are you using (see dpi.h)?
    5.6.2

  2. What OS (and version) is your application on?
    Linux/Manjaro

  3. What compiler (and version) did you use?
    g++ 15.2.1

  4. What is your version of the Oracle Client (e.g. Instant Client)? How was it installed? Where it is installed?
    instantclient 23.9

  5. What is your Oracle Database version?
    19.26

  6. What is the PATH environment variable (on Windows) or LD_LIBRARY_PATH (on Linux) set to?
    /home/oracle/instantclient_23_9

  7. What environment variables did you set? How exactly did you set them?

  8. What problem or error(s) you are seeing?
    dpiConn_close segfaults, gdb backtrace gives

`#0 dpiLob__close (lob=0x555555905910, propagateErrors=1, error=0x7fffffffcfa0) at /media/gweber/Data1/develop/cpp/playground/odpilib/external/odpi-c/dpiLob.c:92

#1 0x00007ffff7d3dda9 in dpiConn__close (conn=0x555555724890, mode=0, tag=0x0, tagLength=0, propagateErrors=1, error=0x7fffffffcfa0)
at /media/gweber/Data1/develop/cpp/playground/odpilib/external/odpi-c/dpiConn.c:235

#2 0x00007ffff7d41a1c in dpiConn_close (conn=0x555555724890, mode=0, tag=0x0, tagLength=0) at /media/gweber/Data1/develop/cpp/playground/odpilib/external/odpi-c/dpiConn.c:1757

#3 0x00007ffff7dbb9c9 in odpilib::Connection::Close (this=0x7fffffffd190) at /media/gweber/Data1/develop/cpp/playground/odpilib/src/Connection.cpp:104

#4 0x0000555555639efd in test_7 (argc=2, argv=0x7fffffffd6a8) at /media/gweber/Data1/develop/cpp/playground/odplibtest/main.cpp:77

#5 0x00005555556686e5 in std::__invoke_impl<void, void (*&)(int, char**), int, char**> (__f=@0x5555556b7a10: 0x555555639c70 <test_7(int, char**)>) at /usr/include/c++/15.2.1/bits/invoke.h:63

#6 0x00005555556649e0 in std::__invoke_r<void, void (*&)(int, char**), int, char**> (__fn=@0x5555556b7a10: 0x555555639c70 <test_7(int, char**)>) at /usr/include/c++/15.2.1/bits/invoke.h:113

#7 0x000055555565e3bb in std::_Function_handler<void(int, char**), void (*)(int, char**)>::_M_invoke (__functor=..., __args#0=@0x7fffffffd4a4: 2, __args#1=@0x7fffffffd498: 0x7fffffffd6a8)
at /usr/include/c++/15.2.1/bits/std_function.h:292

#8 0x000055555564872b in std::function<void(int, char**)>::operator() (this=0x5555556b7a10, __args#0=2, __args#1=0x7fffffffd6a8) at /usr/include/c++/15.2.1/bits/std_function.h:593

#9 0x0000555555639b72 in main (argc=2, argv=0x7fffffffd6a8) at /media/gweber/Data1/develop/cpp/playground/odplibtest/main.cpp:44
`

  1. Do you have a runnable code snippet to describe the problem?

code is part of a larger c++ library. basically it does:

  • open context
  • open connection
  • dpiConn_prepareStmt and dpiStmt_execute statement
  • run dpiStmt_fetch in loop until found = 0, no column values/etc fetched
  • dpiConn_close

why does it try to close a lob?

thanks in advance,
gerald

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugpatch availableAwaiting inclusion in official release

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions