Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
SUSE:SLE-12-SP1:GA
xen.4507
xs-07-do_mkdir-error.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File xs-07-do_mkdir-error.patch of Package xen.4507
commit 7d87d31d33ff7c746290886978d172dcab74369d Author: Wei Liu <wei.liu2@citrix.com> Date: Wed Jul 20 15:13:41 2016 +0100 xenstore: send error earlier in do_mkdir XenServer's coverity instance complains that a few lines below create_node dereferences NULL if name == NULL. It however fails to figure out that if node is NULL, errno won't be ENOENT, so do_mkdir should have bailed before create_node. That said, it would be good if we don't need to go through the hops. We can bail earlier if name is NULL. Signed-off-by: Wei Liu <wei.liu2@citrix.com> Acked-by: Ian Jackson <ian.jackson@eu.citrix.com> Index: xen-4.4.4-testing/tools/xenstore/xenstored_core.c =================================================================== --- xen-4.4.4-testing.orig/tools/xenstore/xenstored_core.c +++ xen-4.4.4-testing/tools/xenstore/xenstored_core.c @@ -971,6 +971,12 @@ static void do_mkdir(struct connection * struct node *node; const char *name = onearg(in); + if (!name) { + errno = EINVAL; + send_error(conn, errno); + return; + } + name = canonicalize(conn, name); node = get_node(conn, in, name, XS_PERM_WRITE);
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor