git://git.camperquake.de
/
zfs.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix gcc uninitialized variable warnings
[zfs.git]
/
module
/
nvpair
/
nvpair.c
diff --git
a/module/nvpair/nvpair.c
b/module/nvpair/nvpair.c
index
8115091
..
282e0f8
100644
(file)
--- a/
module/nvpair/nvpair.c
+++ b/
module/nvpair/nvpair.c
@@
-20,8
+20,7
@@
*/
/*
*/
/*
- * Copyright 2009 Sun Microsystems, Inc. All rights reserved.
- * Use is subject to license terms.
+ * Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.
*/
#include <sys/stropts.h>
*/
#include <sys/stropts.h>
@@
-257,6
+256,12
@@
nvlist_init(nvlist_t *nvl, uint32_t nvflag, nvpriv_t *priv)
nvl->nvl_pad = 0;
}
nvl->nvl_pad = 0;
}
+uint_t
+nvlist_nvflag(nvlist_t *nvl)
+{
+ return (nvl->nvl_nvflag);
+}
+
/*
* nvlist_alloc - Allocate nvlist.
*/
/*
* nvlist_alloc - Allocate nvlist.
*/
@@
-1606,10
+1611,10
@@
nvlist_lookup_nvpair_ei_sep(nvlist_t *nvl, const char *name, const char sep,
{
nvpair_t *nvp;
const char *np;
{
nvpair_t *nvp;
const char *np;
- char *sepp;
+ char *sepp
=NULL
;
char *idxp, *idxep;
nvlist_t **nva;
char *idxp, *idxep;
nvlist_t **nva;
- long idx;
+ long idx
= 0
;
int n;
if (ip)
int n;
if (ip)
@@
-2377,7
+2382,7
@@
nvlist_xpack(nvlist_t *nvl, char **bufp, size_t *buflen, int encoding,
*/
nv_priv_init(&nvpriv, nva, 0);
*/
nv_priv_init(&nvpriv, nva, 0);
- if (
err = nvlist_size(nvl, &alloc_size, encoding
))
+ if (
(err = nvlist_size(nvl, &alloc_size, encoding)
))
return (err);
if ((buf = nv_mem_zalloc(&nvpriv, alloc_size)) == NULL)
return (err);
if ((buf = nv_mem_zalloc(&nvpriv, alloc_size)) == NULL)