search for: 124e19b7

Displaying 3 results from an estimated 3 matches for "124e19b7".

2019 Aug 27
0
[nbdkit PATCH] server: Enforce sane stdin/out/err
...; + fd = open ("/dev/null", O_RDONLY | O_CLOEXEC); + assert (fd == 1); + } /* Don't call the plugin again if quit has been set because the main * thread will be in the process of unloading it. The plugin.unload diff --git a/server/main.c b/server/main.c index 65025a62..124e19b7 100644 --- a/server/main.c +++ b/server/main.c @@ -149,6 +149,17 @@ main (int argc, char *argv[]) size_t i; const char *magic_config_key; + /* Refuse to run if stdin/out/err are closed, whether or not -s is used. */ + if (fcntl (STDERR_FILENO, F_GETFL) == -1) { + /* Nowhere we can repor...
2019 Aug 30
0
[nbdkit PATCH 2/9] server: Consolidate common backend tasks into new backend.c
...e); + set_debug_flags (dl, f->backend.name); /* Call the on-load callback if it exists. */ - debug ("%s: load", f->name); + debug ("%s: load", f->backend.name); if (f->filter.load) f->filter.load (); diff --git a/server/main.c b/server/main.c index 124e19b7..6999818c 100644 --- a/server/main.c +++ b/server/main.c @@ -602,7 +602,7 @@ main (int argc, char *argv[]) display_version (); for_each_backend (b) { - printf ("%s", b->name (b)); + printf ("%s", b->name); if ((v = b->version (b)) != NULL)...
2019 Aug 30
15
[nbdkit PATCH 0/9] can_FOO caching, more filter validation
It's easy to use the sh script to demonstrate that nbdkit is inefficiently calling into .get_size, .can_fua, and friends more than necessary. We've also commented on the list in the past that it would be nice to ensure that when filters call into next_ops, they are not violating constraints (as we've have to fix several bugs in the past where we did not have such checking to protect