Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
R
redoxfs
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
bjorn3
redoxfs
Commits
5e5656f1
Verified
Commit
5e5656f1
authored
5 years ago
by
Jeremy Soller
Browse files
Options
Downloads
Patches
Plain Diff
Make mount points not require an extra reference
parent
86b0d612
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
src/mount/fuse.rs
+1
-1
1 addition, 1 deletion
src/mount/fuse.rs
src/mount/mod.rs
+3
-3
3 additions, 3 deletions
src/mount/mod.rs
src/mount/redox/mod.rs
+1
-1
1 addition, 1 deletion
src/mount/redox/mod.rs
with
5 additions
and
5 deletions
src/mount/fuse.rs
+
1
−
1
View file @
5e5656f1
...
@@ -20,7 +20,7 @@ const TTL: Timespec = Timespec { sec: 1, nsec: 0 }; // 1 second
...
@@ -20,7 +20,7 @@ const TTL: Timespec = Timespec { sec: 1, nsec: 0 }; // 1 second
const
NULL_TIME
:
Timespec
=
Timespec
{
sec
:
0
,
nsec
:
0
};
const
NULL_TIME
:
Timespec
=
Timespec
{
sec
:
0
,
nsec
:
0
};
pub
fn
mount
<
D
:
Disk
,
P
:
AsRef
<
Path
>
,
F
:
FnMut
()
>
(
filesystem
:
filesystem
::
FileSystem
<
D
>
,
mountpoint
:
&
P
,
mut
callback
:
F
,
options
:
&
[
&
OsStr
])
->
io
::
Result
<
()
>
{
pub
fn
mount
<
D
:
Disk
,
P
:
AsRef
<
Path
>
,
F
:
FnMut
()
>
(
filesystem
:
filesystem
::
FileSystem
<
D
>
,
mountpoint
:
P
,
mut
callback
:
F
,
options
:
&
[
&
OsStr
])
->
io
::
Result
<
()
>
{
let
mut
session
=
Session
::
new
(
Fuse
{
let
mut
session
=
Session
::
new
(
Fuse
{
fs
:
filesystem
fs
:
filesystem
},
mountpoint
.as_ref
(),
options
)
?
;
},
mountpoint
.as_ref
(),
options
)
?
;
...
...
This diff is collapsed.
Click to expand it.
src/mount/mod.rs
+
3
−
3
View file @
5e5656f1
...
@@ -11,7 +11,7 @@ mod fuse;
...
@@ -11,7 +11,7 @@ mod fuse;
mod
redox
;
mod
redox
;
#[cfg(target_os
=
"macos"
)]
#[cfg(target_os
=
"macos"
)]
pub
fn
mount
<
D
:
Disk
,
P
:
AsRef
<
Path
>
,
F
:
FnMut
()
>
(
filesystem
:
FileSystem
<
D
>
,
mountpoint
:
&
P
,
callback
:
F
)
->
io
::
Result
<
()
>
{
pub
fn
mount
<
D
:
Disk
,
P
:
AsRef
<
Path
>
,
F
:
FnMut
()
>
(
filesystem
:
FileSystem
<
D
>
,
mountpoint
:
P
,
callback
:
F
)
->
io
::
Result
<
()
>
{
use
std
::
ffi
::
OsStr
;
use
std
::
ffi
::
OsStr
;
fuse
::
mount
(
filesystem
,
mountpoint
,
callback
,
&
[
fuse
::
mount
(
filesystem
,
mountpoint
,
callback
,
&
[
...
@@ -25,11 +25,11 @@ pub fn mount<D: Disk, P: AsRef<Path>, F: FnMut()>(filesystem: FileSystem<D>, mou
...
@@ -25,11 +25,11 @@ pub fn mount<D: Disk, P: AsRef<Path>, F: FnMut()>(filesystem: FileSystem<D>, mou
}
}
#[cfg(all(not(target_os
=
"macos"
),
not(target_os
=
"redox"
)))]
#[cfg(all(not(target_os
=
"macos"
),
not(target_os
=
"redox"
)))]
pub
fn
mount
<
D
:
Disk
,
P
:
AsRef
<
Path
>
,
F
:
FnMut
()
>
(
filesystem
:
FileSystem
<
D
>
,
mountpoint
:
&
P
,
callback
:
F
)
->
io
::
Result
<
()
>
{
pub
fn
mount
<
D
:
Disk
,
P
:
AsRef
<
Path
>
,
F
:
FnMut
()
>
(
filesystem
:
FileSystem
<
D
>
,
mountpoint
:
P
,
callback
:
F
)
->
io
::
Result
<
()
>
{
fuse
::
mount
(
filesystem
,
mountpoint
,
callback
,
&
[])
fuse
::
mount
(
filesystem
,
mountpoint
,
callback
,
&
[])
}
}
#[cfg(target_os
=
"redox"
)]
#[cfg(target_os
=
"redox"
)]
pub
fn
mount
<
D
:
Disk
,
P
:
AsRef
<
Path
>
,
F
:
FnMut
()
>
(
filesystem
:
FileSystem
<
D
>
,
mountpoint
:
&
P
,
callback
:
F
)
->
io
::
Result
<
()
>
{
pub
fn
mount
<
D
:
Disk
,
P
:
AsRef
<
Path
>
,
F
:
FnMut
()
>
(
filesystem
:
FileSystem
<
D
>
,
mountpoint
:
P
,
callback
:
F
)
->
io
::
Result
<
()
>
{
redox
::
mount
(
filesystem
,
mountpoint
,
callback
)
redox
::
mount
(
filesystem
,
mountpoint
,
callback
)
}
}
This diff is collapsed.
Click to expand it.
src/mount/redox/mod.rs
+
1
−
1
View file @
5e5656f1
...
@@ -14,7 +14,7 @@ use self::scheme::FileScheme;
...
@@ -14,7 +14,7 @@ use self::scheme::FileScheme;
pub
mod
resource
;
pub
mod
resource
;
pub
mod
scheme
;
pub
mod
scheme
;
pub
fn
mount
<
D
:
Disk
,
P
:
AsRef
<
Path
>
,
F
:
FnMut
()
>
(
filesystem
:
FileSystem
<
D
>
,
mountpoint
:
&
P
,
mut
callback
:
F
)
->
io
::
Result
<
()
>
{
pub
fn
mount
<
D
:
Disk
,
P
:
AsRef
<
Path
>
,
F
:
FnMut
()
>
(
filesystem
:
FileSystem
<
D
>
,
mountpoint
:
P
,
mut
callback
:
F
)
->
io
::
Result
<
()
>
{
let
mountpoint
=
mountpoint
.as_ref
();
let
mountpoint
=
mountpoint
.as_ref
();
let
mut
socket
=
File
::
create
(
format!
(
":{}"
,
mountpoint
.display
()))
?
;
let
mut
socket
=
File
::
create
(
format!
(
":{}"
,
mountpoint
.display
()))
?
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment