Skip to content

Commit 2745240

Browse files
committed
Remove dead code that static scanning flagged as problematic
1 parent 864d363 commit 2745240

File tree

3 files changed

+1
-50
lines changed

3 files changed

+1
-50
lines changed

src/njs/src/njsConnection.cpp

Lines changed: 0 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,6 @@ void Connection::Init(Handle<Object> target)
128128
Nan::SetPrototypeMethod(tpl, "commit", Commit);
129129
Nan::SetPrototypeMethod(tpl, "rollback", Rollback);
130130
Nan::SetPrototypeMethod(tpl, "break", Break);
131-
Nan::SetPrototypeMethod(tpl, "getLob", GetLob);
132131

133132
Nan::SetAccessor(tpl->InstanceTemplate(),
134133
Nan::New<v8::String>("stmtCacheSize").ToLocalChecked(),
@@ -3392,45 +3391,6 @@ v8::Local<v8::Value> Connection::NewLob(eBaton* executeBaton,
33923391

33933392

33943393

3395-
/*****************************************************************************/
3396-
/*
3397-
DESCRIPTION
3398-
GetLob method on Connection class.
3399-
3400-
PARAMETERS
3401-
none
3402-
RETURNS
3403-
A Lob object
3404-
3405-
NOTES
3406-
Shows example method to call the Oracledb.newLob() method from a
3407-
Connection class method. That is, Connection.getLob() calls
3408-
Oracledb.newLob().
3409-
3410-
This method is unused as we call Oracledb.newLob() from the C++
3411-
Connection::NewLob() method in Connection::GetValue(). This is much more
3412-
performant than going across language boundries twice to get a Lob.
3413-
*/
3414-
3415-
NAN_METHOD(Connection::GetLob)
3416-
{
3417-
Connection *connection = Nan::ObjectWrap::Unwrap<Connection>(info.This());
3418-
3419-
NJS_CHECK_OBJECT_VALID2 ( connection, info );
3420-
3421-
Local<Object> jsOracledb = Nan::New<Object>(
3422-
connection->oracledb_->jsOracledb);
3423-
Local<Value> argv[1];
3424-
3425-
Local<Value> result = Local<Function>::Cast(
3426-
jsOracledb->Get(
3427-
Nan::New<v8::String>(
3428-
"newLob").ToLocalChecked()))->Call(
3429-
jsOracledb, 1, argv);
3430-
3431-
info.GetReturnValue().Set(result);
3432-
}
3433-
34343394

34353395

34363396
/* end of file njsConnection.cpp */

src/njs/src/njsConnection.h

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -389,13 +389,10 @@ class Connection: public Nan::ObjectWrap
389389
dvoid **bufpp, void **alenpp, void **indpp,
390390
unsigned short **rcode, unsigned char *piecep );
391391

392-
// GetLob Method on Connection class
392+
// NewLob Method on Connection class
393393
static v8::Local<v8::Value> NewLob(eBaton* executeBaton,
394394
ProtoILob *protoILob);
395395

396-
static NAN_METHOD(GetLob);
397-
398-
399396
dpi::Conn* dpiconn_;
400397
bool isValid_;
401398
unsigned int oracleServerVersion_;

src/njs/src/njsIntLob.h

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -190,12 +190,6 @@ class ILob : public Nan::ObjectWrap
190190
static void Async_Write (uv_work_t *req);
191191
static void Async_AfterWrite (uv_work_t *req);
192192

193-
// GetLob Method on ILob class
194-
static NAN_METHOD(GetLob);
195-
static void Async_GetLob (uv_work_t *req);
196-
static void Async_AfterGetLob (uv_work_t *req);
197-
198-
199193
Descriptor *lobLocator_;
200194
unsigned short fetchType_;
201195

0 commit comments

Comments
 (0)