Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

a error will happen on windows: oci_generated_10.py&oci_generated_11.py #1

Open
idlesysman opened this issue Jan 8, 2013 · 0 comments

Comments

@idlesysman
Copy link

oci_generated_10.py
_libs["libclntsh.so.10.1"]

oci_generated_11.py
_libs["libclntsh.so.11.1"]

on windows it's "oci.dll" not "libclntsh*".

also see:http://docs.oracle.com/cd/B28359_01/appdev.111/b28390/install.htm

K0Te pushed a commit to K0Te/cx_oracle_on_ctypes that referenced this issue Oct 1, 2015
Previous implementation could fail in following ways in
multi-thread environment:
Scenario lameiro#1 - one-time failure:
t1 changes arguments of OCIHandleAlloc;
t2 calls oci.OCIHandleAlloc(), expecting to call original one, fails
with exception;
t1 restores arguments of OCIHandleAlloc.

Scenario lameiro#2 - failure till process restart:
t1 changes arguments of OCIHandleAlloc to wrapped(o->w1);
t2 changes arguments of OCIHandleAlloc to new wrapped(w1->w2);
t1 restores arguments of OCIHandleAlloc to original(w1->o);
t2 restores arguments of OCIHandleAlloc to wrapped(w2->w1).
As a result, original args for OCIHandleAlloc are nowhere to be found
and library fails to connect to DB.

Proposed solution is to create copies of args instead of modifying
global state.
lameiro pushed a commit that referenced this issue Oct 20, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant