Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
R
rust-rocksdb
Project
Project
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
fangzongwu
rust-rocksdb
Commits
ca977812
Commit
ca977812
authored
Aug 03, 2016
by
siddontang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
*: Address comment
parent
eb27fcf7
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
14 deletions
+16
-14
rocksdb.rs
src/rocksdb.rs
+16
-14
No files found.
src/rocksdb.rs
View file @
ca977812
...
...
@@ -831,17 +831,19 @@ impl DB {
sizes
}
pub
fn
delete_file_in_range
(
&
self
,
r
:
Range
)
->
Result
<
(),
String
>
{
pub
fn
delete_file_in_range
(
&
self
,
start_key
:
&
[
u8
],
end_key
:
&
[
u8
])
->
Result
<
(),
String
>
{
unsafe
{
let
mut
err
:
*
const
i8
=
0
as
*
const
i8
;
let
err_ptr
:
*
mut
*
const
i8
=
&
mut
err
;
rocksdb_ffi
::
rocksdb_delete_file_in_range
(
self
.inner
,
r
.
start_key
.as_ptr
(),
r
.
start_key
.len
()
as
size_t
,
r
.
end_key
.as_ptr
(),
r
.
end_key
.len
()
as
size_t
,
err_pt
r
);
start_key
.as_ptr
(),
start_key
.len
()
as
size_t
,
end_key
.as_ptr
(),
end_key
.len
()
as
size_t
,
&
mut
er
r
);
if
!
err
.is_null
()
{
return
Err
(
error_message
(
err
));
}
...
...
@@ -851,19 +853,19 @@ impl DB {
pub
fn
delete_file_in_range_cf
(
&
self
,
cf
:
DBCFHandle
,
r
:
Range
)
start_key
:
&
[
u8
],
end_key
:
&
[
u8
])
->
Result
<
(),
String
>
{
unsafe
{
let
mut
err
:
*
const
i8
=
0
as
*
const
i8
;
let
err_ptr
:
*
mut
*
const
i8
=
&
mut
err
;
rocksdb_ffi
::
rocksdb_delete_file_in_range_cf
(
self
.inner
,
cf
,
r
.
start_key
.as_ptr
(),
r
.
start_key
.len
()
as
size_t
,
r
.
end_key
.as_ptr
(),
r
.
end_key
.len
()
as
size_t
,
err_pt
r
);
start_key
.as_ptr
(),
start_key
.len
()
as
size_t
,
end_key
.as_ptr
(),
end_key
.len
()
as
size_t
,
&
mut
er
r
);
if
!
err
.is_null
()
{
return
Err
(
error_message
(
err
));
}
...
...
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