search for: 23aa204

Displaying 2 results from an estimated 2 matches for "23aa204".

Did you mean: 23.204
2019 Feb 08
0
[PATCH nbdkit] Add support for writing plugins in Rust.
...el> + +=back + +=head1 SEE ALSO + +L<nbdkit(1)>, +L<nbdkit-plugin(3)>, +L<cargo(1)>. + +=head1 AUTHORS + +Richard W.M. Jones + +=head1 COPYRIGHT + +Copyright (C) 2019 Red Hat Inc. diff --git a/plugins/rust/src/lib.rs b/plugins/rust/src/lib.rs new file mode 100644 index 0000000..23aa204 --- /dev/null +++ b/plugins/rust/src/lib.rs @@ -0,0 +1,155 @@ +// nbdkit +// Copyright (C) 2019 Red Hat Inc. +// All rights reserved. +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are +// met: +// +/...
2019 Feb 08
3
[PATCH nbdkit] Add support for writing plugins in Rust.
This adds very rough support for writing nbdkit plugins in Rust. This is not very idiomatic -- essentially we're handling the direct C calls from nbdkit in Rust. We have to use ‘unsafe’ in a few places because there's no way to tell the Rust code that nbdkit satisfies guarantees (eg. around thread safety, always returning leaked pointers back to the close function, always doing bounds