Skip to content

Commit 29d3b80

Browse files
committed
Fixed AIX-specific REF CURSOR related failures
1 parent be5de21 commit 29d3b80

File tree

5 files changed

+9
-7
lines changed

5 files changed

+9
-7
lines changed

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
## node-oracledb v1.2.0 (DD Mon YYYY)
44

5+
- Fixed AIX-specific REF CURSOR related failures.
6+
57
- Optimized CLOB memory allocation to account for different database-to-client character set expansions.
68

79
- Fixed a crash while reading a LOB from a closed connection

src/dpi/include/dpiStmt.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -198,7 +198,7 @@ class Stmt
198198

199199
virtual OCIError *getError () = 0;
200200

201-
virtual unsigned long getState () = 0;
201+
virtual unsigned int getState () = 0;
202202

203203
virtual ~Stmt(){};
204204

src/dpi/src/dpiStmtImpl.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -729,15 +729,15 @@ bool StmtImpl::isReturning ()
729729
One of the possible values DpiStmtState
730730
(DpiStmtStateInitialized, DpiStmtStateExecute, DpiStmtEndOfFetch)
731731
*/
732-
unsigned long StmtImpl::getState ()
732+
unsigned int StmtImpl::getState ()
733733
{
734734
if ( state_ == DPI_STMT_STATE_UNDEFINED )
735735
{
736-
ociCall (OCIAttrGet (stmth_, OCI_HTYPE_STMT, (ub4*)&state_, NULL,
736+
ociCall (OCIAttrGet (stmth_, OCI_HTYPE_STMT, &state_, NULL,
737737
OCI_ATTR_STMT_STATE, errh_ ), errh_ );
738738
}
739739

740-
return state_;
740+
return ( unsigned int ) state_;
741741
}
742742

743743

src/dpi/src/dpiStmtImpl.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ class StmtImpl : public Stmt
9494

9595
virtual OCIError * getError () { return errh_; }
9696

97-
virtual unsigned long getState ();
97+
virtual unsigned int getState ();
9898

9999

100100
// Is the SQL statement DML or not ?
@@ -137,7 +137,7 @@ class StmtImpl : public Stmt
137137
bool isReturning_; // Does the stmt has RETURNING INTO clause?
138138
bool isReturningSet_; // Has isReturning_ flag queried & set.
139139
bool refCursor_; // refCursor or not.
140-
unsigned long state_; // OCI Stmt State
140+
ub4 state_; // OCI Stmt State
141141
};
142142

143143

src/njs/src/njsConnection.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -943,7 +943,7 @@ void Connection::Async_Execute (uv_work_t *req)
943943
/* Here bind->isOut is expected to be TRUE, and is checked earlier */
944944
if ( bind->type == dpi::DpiRSet )
945945
{
946-
unsigned long state = ((Stmt*)bind->value)->getState ();
946+
unsigned int state = ((Stmt*)bind->value)->getState ();
947947

948948
if ( state == DPI_STMT_STATE_EXECUTED )
949949
{

0 commit comments

Comments
 (0)