Update to latest std
This commit is contained in:
parent
e7a0f74aeb
commit
adc2102dc1
@ -67,15 +67,15 @@ fn callback(call: IncomingCall) {
|
|||||||
let server_lock = SERVER.read();
|
let server_lock = SERVER.read();
|
||||||
let server = server_lock.as_ref().unwrap();
|
let server = server_lock.as_ref().unwrap();
|
||||||
if call.func == 0 {
|
if call.func == 0 {
|
||||||
let kind = postcard::from_bytes(&call.args).unwrap();
|
let kind = postcard::from_bytes(call.args()).unwrap();
|
||||||
let ret = postcard::to_stdvec(&server.register_fs(call.from, kind)).unwrap();
|
let ret = postcard::to_stdvec(&server.register_fs(call.from, kind)).unwrap();
|
||||||
call.send_return(&ret);
|
call.send_return(&ret);
|
||||||
} else if call.func == 1 {
|
} else if call.func == 1 {
|
||||||
let (dev, kind, path) = postcard::from_bytes(&call.args).unwrap();
|
let (dev, kind, path) = postcard::from_bytes(call.args()).unwrap();
|
||||||
let ret = postcard::to_stdvec(&server.mount(dev, kind, path)).unwrap();
|
let ret = postcard::to_stdvec(&server.mount(dev, kind, path)).unwrap();
|
||||||
call.send_return(&ret);
|
call.send_return(&ret);
|
||||||
} else if call.func == 2 {
|
} else if call.func == 2 {
|
||||||
let path = postcard::from_bytes(&call.args).unwrap();
|
let path = postcard::from_bytes(call.args()).unwrap();
|
||||||
let ret = postcard::to_stdvec(&server.open(path)).unwrap();
|
let ret = postcard::to_stdvec(&server.open(path)).unwrap();
|
||||||
call.send_return(&ret);
|
call.send_return(&ret);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user