Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
I
interface-test
Project
Project
Details
Activity
Releases
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
董子豪
interface-test
Commits
1dca9e59
Commit
1dca9e59
authored
Aug 11, 2021
by
董子豪
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
test
parent
f044b3a0
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
fs.go
extern/sector-storage/ffiwrapper/basicfs/fs.go
+2
-2
No files found.
extern/sector-storage/ffiwrapper/basicfs/fs.go
View file @
1dca9e59
...
...
@@ -24,7 +24,7 @@ type Provider struct {
waitSector
map
[
sectorFile
]
chan
struct
{}
}
func
(
b
*
Provider
)
AcquireSector
(
ctx
context
.
Context
,
id
storage
.
SectorRef
,
existing
storiface
.
SectorFileType
,
allocate
storiface
.
SectorFileType
,
ptype
storiface
.
PathType
)
(
storiface
.
SectorPaths
,
func
(),
error
)
{
func
(
b
*
Provider
)
AcquireSector
(
ctx
context
.
Context
,
id
storage
.
SectorRef
,
existing
storiface
.
SectorFileType
,
allocate
storiface
.
SectorFileType
,
ptype
storiface
.
PathType
,
numbers
...
int32
)
(
storiface
.
SectorPaths
,
func
(),
error
)
{
if
err
:=
os
.
Mkdir
(
filepath
.
Join
(
b
.
Root
,
storiface
.
FTUnsealed
.
String
()),
0755
);
err
!=
nil
&&
!
os
.
IsExist
(
err
)
{
// nolint
return
storiface
.
SectorPaths
{},
nil
,
err
}
...
...
@@ -64,7 +64,7 @@ func (b *Provider) AcquireSector(ctx context.Context, id storage.SectorRef, exis
return
storiface
.
SectorPaths
{},
nil
,
ctx
.
Err
()
}
path
:=
filepath
.
Join
(
b
.
Root
,
fileType
.
String
(),
storiface
.
SectorName
(
id
.
ID
))
path
:=
filepath
.
Join
(
b
.
Root
,
fileType
.
String
(),
storiface
.
SectorName
(
id
.
ID
,
numbers
...
))
prevDone
:=
done
done
=
func
()
{
...
...
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