summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorToomas Soome <tsoome@me.com>2019-01-26 12:34:15 +0200
committerToomas Soome <tsoome@me.com>2019-07-20 21:27:32 +0300
commita7a204a5df2f23dc42b122bd7adc565f35bcf22c (patch)
tree553556b52e4bbce487f7f399ddaaadec6605f1c4
parent9e364aca663e830f5a1b48c9d16cdff4c766c85d (diff)
downloadillumos-joyent-a7a204a5df2f23dc42b122bd7adc565f35bcf22c.tar.gz
11393 ndmpadm: NULL pointer errors
Reviewed by: Andy Fiddaman <omnios@citrus-it.co.uk> Approved by: Garrett D'Amore <garrett@damore.org>
-rw-r--r--usr/src/cmd/ndmpadm/ndmpadm_print.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/usr/src/cmd/ndmpadm/ndmpadm_print.c b/usr/src/cmd/ndmpadm/ndmpadm_print.c
index 25458708ef..b9ca186a37 100644
--- a/usr/src/cmd/ndmpadm/ndmpadm_print.c
+++ b/usr/src/cmd/ndmpadm/ndmpadm_print.c
@@ -10,10 +10,10 @@
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
- * - Redistributions of source code must retain the above copyright
+ * - Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
- * - Redistributions in binary form must reproduce the above copyright
+ * - Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in
* the documentation and/or other materials provided with the
* distribution.
@@ -104,7 +104,7 @@ ndmp_print_env(ndmp_session_info_t *si)
for (i = 0; ep && i < n; i++, ep++) {
(void) fprintf(stdout, gettext("\tdata.env[%d]:\t%s: "),
i, ep->np_name);
- if ((ep->np_value != NULL) && (*ep->np_value != NULL))
+ if ((ep->np_value != NULL) && (*ep->np_value != '\0'))
(void) fprintf(stdout, "\"%s\"\n", ep->np_value);
}
}