projects
/
platform
/
upstream
/
curl.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Base code merged to SPIN 2.4
[platform/upstream/curl.git]
/
src
/
tool_xattr.c
diff --git
a/src/tool_xattr.c
b/src/tool_xattr.c
index
b2666d9
..
da0cad6
100644
(file)
--- a/
src/tool_xattr.c
+++ b/
src/tool_xattr.c
@@
-5,7
+5,7
@@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 201
3
, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 201
4
, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@
-56,11
+56,12
@@
int fwrite_xattr(CURL *curl, int fd)
{
int i = 0;
int err = 0;
{
int i = 0;
int err = 0;
+
/* loop through all xattr-curlinfo pairs and abort on a set error */
while(err == 0 && mappings[i].attr != NULL) {
char *value = NULL;
/* loop through all xattr-curlinfo pairs and abort on a set error */
while(err == 0 && mappings[i].attr != NULL) {
char *value = NULL;
- CURLcode r
c
= curl_easy_getinfo(curl, mappings[i].info, &value);
- if(
rc == CURLE_OK
&& value) {
+ CURLcode r
esult
= curl_easy_getinfo(curl, mappings[i].info, &value);
+ if(
!result
&& value) {
#ifdef HAVE_FSETXATTR_6
err = fsetxattr(fd, mappings[i].attr, value, strlen(value), 0, 0);
#elif defined(HAVE_FSETXATTR_5)
#ifdef HAVE_FSETXATTR_6
err = fsetxattr(fd, mappings[i].attr, value, strlen(value), 0, 0);
#elif defined(HAVE_FSETXATTR_5)
@@
-75,6
+76,7
@@
int fwrite_xattr(CURL *curl, int fd)
}
i++;
}
}
i++;
}
+
return err;
}
#else
return err;
}
#else
@@
-82,6
+84,7
@@
int fwrite_xattr(CURL *curl, int fd)
{
(void)curl;
(void)fd;
{
(void)curl;
(void)fd;
+
return 0;
}
#endif
return 0;
}
#endif