diff options
| -rw-r--r-- | cli/src/cli-rpc-ops.c | 3 | ||||
| -rw-r--r-- | libglusterfs/src/compat.c | 21 | ||||
| -rw-r--r-- | libglusterfs/src/compat.h | 2 | ||||
| -rw-r--r-- | rpc/xdr/src/cli1-xdr.h | 7 | 
4 files changed, 29 insertions, 4 deletions
diff --git a/cli/src/cli-rpc-ops.c b/cli/src/cli-rpc-ops.c index daeb927657c..761c67cbbb5 100644 --- a/cli/src/cli-rpc-ops.c +++ b/cli/src/cli-rpc-ops.c @@ -42,6 +42,7 @@  #include "glusterfs3.h"  #include "portmap.h" +#include "syscall.h"  extern rpc_clnt_prog_t *cli_rpc_prog;  extern int              cli_op_ret; @@ -1400,7 +1401,7 @@ gf_cli3_1_print_limit_list (char *volname, char *limit_list,                  memset (&cmd_str, 0, sizeof (cmd_str));                  snprintf (cmd_str, sizeof (cmd_str), "%s/%s", mountdir, path); -                ret = getxattr (cmd_str, "trusted.limit.list", (void *) ret_str, 4096); +                ret = sys_lgetxattr (cmd_str, "trusted.limit.list", (void *) ret_str, 4096);                  if (ret < 0) {                          cli_out ("%-20s %10s", path, value);                  } else { diff --git a/libglusterfs/src/compat.c b/libglusterfs/src/compat.c index 90b86d20de5..a5a49d4e6a1 100644 --- a/libglusterfs/src/compat.c +++ b/libglusterfs/src/compat.c @@ -528,6 +528,27 @@ solaris_rename (const char *old_path, const char *new_path)          return rename(old_path, new_path);  } + + +char * +mkdtemp (char *tempstring) +{ +        char *new_string = NULL; +        int   ret        = 0; + +        new_string = mktemp (tempstring); +        if (!new_string) +                goto out; + +        ret = mkdir (new_string, 0700); +        if (ret < 0) +                new_string = NULL; + +out: +        return new_string; +} + +  #endif /* GF_SOLARIS_HOST_OS */  #ifndef HAVE_STRNLEN diff --git a/libglusterfs/src/compat.h b/libglusterfs/src/compat.h index b37307f40ac..b04a71df4f0 100644 --- a/libglusterfs/src/compat.h +++ b/libglusterfs/src/compat.h @@ -287,7 +287,7 @@ int solaris_unlink (const char *pathname);  #define GF_SOLARIS_XATTR_DIR ".glusterfs_xattr_inode"  int solaris_xattr_resolve_path (const char *real_path, char **path); - +char *mkdtemp (char *__template);  #endif /* GF_SOLARIS_HOST_OS */  #ifndef HAVE_ARGP diff --git a/rpc/xdr/src/cli1-xdr.h b/rpc/xdr/src/cli1-xdr.h index d1cf56851f2..f77e20b6bc7 100644 --- a/rpc/xdr/src/cli1-xdr.h +++ b/rpc/xdr/src/cli1-xdr.h @@ -17,10 +17,13 @@    <http://www.gnu.org/licenses/>.  */  /* - * Please do not edit this file. - * It was generated using rpcgen. + * Most content of this file is generated using rpcgen. There are very few + * additions done to this file (changes can be seen by running 'rpcgen' + * and taking a diff of this file with rpcgen generated file   */ +#include "xdr-common.h" +  #ifndef _CLI1_XDR_H_RPCGEN  #define _CLI1_XDR_H_RPCGEN  | 
