Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:sschapiro:openstack:upstream
attr
attr-2.4.43-leak.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File attr-2.4.43-leak.patch of Package attr
diff --git a/libattr/attr_copy_action.c b/libattr/attr_copy_action.c index 0d7aca5..dc94224 100644 --- a/libattr/attr_copy_action.c +++ b/libattr/attr_copy_action.c @@ -53,7 +53,7 @@ free_attr_actions(void) static int attr_parse_attr_conf(struct error_context *ctx) { - char *text, *t; + char *text = NULL, *t; size_t size_guess = 4096, len; FILE *file; char *pattern = NULL; @@ -64,15 +64,16 @@ attr_parse_attr_conf(struct error_context *ctx) return 0; repeat: - text = malloc(size_guess + 1); - if (!text) - goto fail; - if ((file = fopen(ATTR_CONF, "r")) == NULL) { if (errno == ENOENT) return 0; goto fail; } + + text = malloc(size_guess + 1); + if (!text) + goto fail; + len = fread(text, 1, size_guess, file); if (ferror(file)) goto fail;
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