blob: 06afba1aa63ea7e82b0f77d2e3a469ad19b03868 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
Index: bootadm/usr/src/cmd/boot/bootadm/bootadm.c
===================================================================
--- bootadm.orig/usr/src/cmd/boot/bootadm/bootadm.c 2012-12-29 17:48:08.230210383 +0400
+++ bootadm/usr/src/cmd/boot/bootadm/bootadm.c 2012-12-29 19:27:56.311517916 +0400
@@ -923,13 +923,13 @@
assert(which);
assert(setting);
- if (*which != NULL) {
+ if (*which != '\0') {
/*
* If "which" is not a number, assume it's a setting we want
* to look for and so set up the routine to look for "which"
* in the default entry.
*/
- while (*p != NULL)
+ while (*p != '\0')
if (!(isdigit((int)*p++))) {
setting = which;
which = mp->curdefault->arg;
@@ -950,10 +950,10 @@
return (BAM_ERROR);
}
- found = (*setting == NULL);
+ found = (*setting == '\0');
for (lp = ent->start; lp != NULL; lp = lp->next) {
- if ((*setting == NULL) && (lp->flags != BAM_COMMENT))
+ if ((*setting == '\0') && (lp->flags != BAM_COMMENT))
bam_print(PRINT, lp->line);
else if (lp->cmd != NULL && strcmp(setting, lp->cmd) == 0) {
bam_print(PRINT, lp->arg);
|