Print error messages as-is, when they don't conform to
<errno> [<parameter> 'value'] These are error messages from (lib)geom itself.
This commit is contained in:
parent
e419ba879f
commit
08b6360ca3
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=185496
@ -525,12 +525,15 @@ gpart_issue(struct gctl_req *req, unsigned int fl __unused)
|
|||||||
}
|
}
|
||||||
|
|
||||||
error = strtol(errstr, &errmsg, 0);
|
error = strtol(errstr, &errmsg, 0);
|
||||||
while (errmsg[0] == ' ')
|
if (errmsg != errstr) {
|
||||||
errmsg++;
|
while (errmsg[0] == ' ')
|
||||||
if (errmsg[0] != '\0')
|
errmsg++;
|
||||||
warnc(error, "%s", errmsg);
|
if (errmsg[0] != '\0')
|
||||||
else
|
warnc(error, "%s", errmsg);
|
||||||
warnc(error, NULL);
|
else
|
||||||
|
warnc(error, NULL);
|
||||||
|
} else
|
||||||
|
warnx("%s", errmsg);
|
||||||
|
|
||||||
status = EXIT_FAILURE;
|
status = EXIT_FAILURE;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user