Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
node-sqlite3
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
俞永鹏
node-sqlite3
Commits
f04f70c6
Commit
f04f70c6
authored
Mar 25, 2010
by
Ryan Dahl
Committed by
Orlando Vazquez
Mar 25, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove * operator on Sqlite3Db
parent
f8f40c3e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
8 deletions
+6
-8
sqlite3_bindings.cc
sqlite3_bindings.cc
+6
-8
No files found.
sqlite3_bindings.cc
View file @
f04f70c6
...
@@ -105,8 +105,6 @@ protected:
...
@@ -105,8 +105,6 @@ protected:
sqlite3
*
db_
;
sqlite3
*
db_
;
operator
sqlite3
*
()
const
{
return
db_
;
}
// Return a pointer to the Sqlite handle pointer so that EIO_Open can
// Return a pointer to the Sqlite handle pointer so that EIO_Open can
// pass it to sqlite3_open which wants a pointer to an sqlite3 pointer. This
// pass it to sqlite3_open which wants a pointer to an sqlite3 pointer. This
// is because it wants to initialize our original (sqlite3*) pointer to
// is because it wants to initialize our original (sqlite3*) pointer to
...
@@ -217,8 +215,8 @@ protected:
...
@@ -217,8 +215,8 @@ protected:
// TODO: libeio'fy
// TODO: libeio'fy
static
Handle
<
Value
>
Changes
(
const
Arguments
&
args
)
{
static
Handle
<
Value
>
Changes
(
const
Arguments
&
args
)
{
HandleScope
scope
;
HandleScope
scope
;
Sqlite3Db
*
db
=
ObjectWrap
::
Unwrap
<
Sqlite3Db
>
(
args
.
This
());
Sqlite3Db
*
db
o
=
ObjectWrap
::
Unwrap
<
Sqlite3Db
>
(
args
.
This
());
Local
<
Number
>
result
=
Integer
::
New
(
sqlite3_changes
(
*
db
));
Local
<
Number
>
result
=
Integer
::
New
(
sqlite3_changes
(
dbo
->
db_
));
return
scope
.
Close
(
result
);
return
scope
.
Close
(
result
);
}
}
...
@@ -260,7 +258,7 @@ protected:
...
@@ -260,7 +258,7 @@ protected:
static
int
EIO_Close
(
eio_req
*
req
)
{
static
int
EIO_Close
(
eio_req
*
req
)
{
struct
close_request
*
close_req
=
(
struct
close_request
*
)(
req
->
data
);
struct
close_request
*
close_req
=
(
struct
close_request
*
)(
req
->
data
);
Sqlite3Db
*
dbo
=
close_req
->
dbo
;
Sqlite3Db
*
dbo
=
close_req
->
dbo
;
int
rc
=
req
->
result
=
sqlite3_close
(
*
dbo
);
int
rc
=
req
->
result
=
sqlite3_close
(
dbo
->
db_
);
dbo
->
db_
=
NULL
;
dbo
->
db_
=
NULL
;
return
0
;
return
0
;
}
}
...
@@ -295,8 +293,8 @@ protected:
...
@@ -295,8 +293,8 @@ protected:
// TODO: libeio'fy
// TODO: libeio'fy
static
Handle
<
Value
>
LastInsertRowid
(
const
Arguments
&
args
)
{
static
Handle
<
Value
>
LastInsertRowid
(
const
Arguments
&
args
)
{
HandleScope
scope
;
HandleScope
scope
;
Sqlite3Db
*
db
=
ObjectWrap
::
Unwrap
<
Sqlite3Db
>
(
args
.
This
());
Sqlite3Db
*
db
o
=
ObjectWrap
::
Unwrap
<
Sqlite3Db
>
(
args
.
This
());
Local
<
Number
>
result
=
Integer
::
New
(
sqlite3_last_insert_rowid
(
*
db
));
Local
<
Number
>
result
=
Integer
::
New
(
sqlite3_last_insert_rowid
(
dbo
->
db_
));
return
scope
.
Close
(
result
);
return
scope
.
Close
(
result
);
}
}
...
@@ -385,7 +383,7 @@ protected:
...
@@ -385,7 +383,7 @@ protected:
prep_req
->
stmt
=
NULL
;
prep_req
->
stmt
=
NULL
;
prep_req
->
tail
=
NULL
;
prep_req
->
tail
=
NULL
;
sqlite3
*
db
=
*
(
prep_req
->
dbo
)
;
sqlite3
*
db
=
prep_req
->
dbo
->
db_
;
int
rc
=
sqlite3_prepare_v2
(
db
,
prep_req
->
sql
,
-
1
,
int
rc
=
sqlite3_prepare_v2
(
db
,
prep_req
->
sql
,
-
1
,
&
(
prep_req
->
stmt
),
&
(
prep_req
->
tail
));
&
(
prep_req
->
stmt
),
&
(
prep_req
->
tail
));
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment