Commit 66dad039 authored by Aaron Jacobs's avatar Aaron Jacobs

Convert

parent e6656ea8
...@@ -15,7 +15,6 @@ ...@@ -15,7 +15,6 @@
package fuseops package fuseops
import ( import (
"sync"
"time" "time"
"golang.org/x/net/context" "golang.org/x/net/context"
...@@ -23,16 +22,17 @@ import ( ...@@ -23,16 +22,17 @@ import (
"github.com/jacobsa/bazilfuse" "github.com/jacobsa/bazilfuse"
) )
// Convert the supplied bazilfuse request struct to an Op, returning nil if it
// is unknown.
//
// This function is an implementation detail of the fuse package, and must not // This function is an implementation detail of the fuse package, and must not
// be called by anyone else. // be called by anyone else.
//
// Convert the supplied bazilfuse request struct to an Op, returning nil if it
// is unknown. finished will be called with the error supplied to o.Respond
// when the user invokes that method.
func Convert( func Convert(
parentCtx context.Context, opCtx context.Context,
r bazilfuse.Request, r bazilfuse.Request,
logForOp func(int, string, ...interface{}), logForOp func(int, string, ...interface{}),
opsInFlight *sync.WaitGroup) (o Op) { finished func(error)) (o Op) {
var co *commonOp var co *commonOp
switch typed := r.(type) { switch typed := r.(type) {
...@@ -215,7 +215,7 @@ func Convert( ...@@ -215,7 +215,7 @@ func Convert(
return return
} }
co.init(parentCtx, o, r, logForOp, opsInFlight) co.init(opCtx, o, r, logForOp, finished)
return return
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment