diff options
Diffstat (limited to 'usr/src/common')
-rw-r--r-- | usr/src/common/dis/i386/dis_tables.c | 4 | ||||
-rw-r--r-- | usr/src/common/fs/hsfs.c | 5 | ||||
-rw-r--r-- | usr/src/common/fs/ufsops.c | 9 | ||||
-rw-r--r-- | usr/src/common/util/string.c | 2 |
4 files changed, 12 insertions, 8 deletions
diff --git a/usr/src/common/dis/i386/dis_tables.c b/usr/src/common/dis/i386/dis_tables.c index 928fa51916..4d26a7ac2c 100644 --- a/usr/src/common/dis/i386/dis_tables.c +++ b/usr/src/common/dis/i386/dis_tables.c @@ -3626,7 +3626,7 @@ dtrace_get_operand(dis86_t *x, uint_t mode, uint_t r_m, int wbit, int opindex) int dtrace_disx86(dis86_t *x, uint_t cpu_mode) { - const instable_t *dp; /* decode table being used */ + const instable_t *dp = NULL; /* decode table being used */ #ifdef DIS_TEXT uint_t i; #endif @@ -6406,6 +6406,8 @@ L_VEX_RM: done: #ifdef DIS_MEM + if (dp == NULL) + return (1); /* * compute the size of any memory accessed by the instruction */ diff --git a/usr/src/common/fs/hsfs.c b/usr/src/common/fs/hsfs.c index 9efe265cfa..e648d03360 100644 --- a/usr/src/common/fs/hsfs.c +++ b/usr/src/common/fs/hsfs.c @@ -23,8 +23,6 @@ * Use is subject to license terms. */ -#pragma ident "%Z%%M% %I% %E% SMI" - /* * Basic file system reading code for standalone I/O system. * Simulates a primitive UNIX I/O system (read(), write(), open(), etc). @@ -174,7 +172,7 @@ opendir(ino_t inode, fileid_t *filep) filep->fi_blocknum = hdbtodb(inode); if (inode != root_ino) - return (0); + return (0); if (parse_dir(filep, 0, &hsdep) > 0) { struct inode *ip; @@ -198,6 +196,7 @@ find(char *path, fileid_t *filep) char c; ino_t n; + n = 0; dprintf("find: %s\n", path); if (path == NULL || *path == '\0') return (0); diff --git a/usr/src/common/fs/ufsops.c b/usr/src/common/fs/ufsops.c index 52e716f1de..a467f41202 100644 --- a/usr/src/common/fs/ufsops.c +++ b/usr/src/common/fs/ufsops.c @@ -69,15 +69,15 @@ static fileid_t *head; devid_t *ufs_devp; struct dirinfo { - int loc; + int loc; fileid_t *fi; }; static int bufs_close(int); static void bufs_closeall(int); -static ino_t find(fileid_t *filep, char *path); +static ino_t find(fileid_t *filep, char *path); static ino_t dlook(fileid_t *filep, char *path); -static daddr32_t sbmap(fileid_t *filep, daddr32_t bn); +static daddr32_t sbmap(fileid_t *filep, daddr32_t bn); static struct direct *readdir(struct dirinfo *dstuff); static void set_cache(int, void *, uint_t); static void *get_cache(int); @@ -151,9 +151,10 @@ find(fileid_t *filep, char *path) int len, r; devid_t *devp; + inode = 0; if (path == NULL || *path == '\0') { printf("null path\n"); - return ((ino_t)0); + return (inode); } dprintf("openi: %s\n", path); diff --git a/usr/src/common/util/string.c b/usr/src/common/util/string.c index 5fe5ddab13..2ed2791eda 100644 --- a/usr/src/common/util/string.c +++ b/usr/src/common/util/string.c @@ -80,6 +80,8 @@ vsnprintf(char *buf, size_t buflen, const char *fmt, va_list aargs) int numwidth; va_list args; + ul = 0; + bs = NULL; /* * Make a copy so that all our callers don't have to make a copy */ |