summaryrefslogtreecommitdiffstats
path: root/sbin
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2008-01-30 13:29:10 +0000
committerjhb <jhb@FreeBSD.org>2008-01-30 13:29:10 +0000
commit100288925824644ec34f1edf0c814f9fa69c20e8 (patch)
tree83113472fca668a8baaf82b64601be4c1a752f8a /sbin
parent5b1d998fc12828f863b1b8fbf2e1db396d2a5d95 (diff)
downloadFreeBSD-src-100288925824644ec34f1edf0c814f9fa69c20e8.zip
FreeBSD-src-100288925824644ec34f1edf0c814f9fa69c20e8.tar.gz
Map 'boot' to GPT_ENT_TYPE_FREEBSD_BOOT when parsuing UUIDs so that things
like 'gpt add -t boot' work. MFC after: 1 week Submitted by: Niki Denev nike_d of cytexbg.com
Diffstat (limited to 'sbin')
-rw-r--r--sbin/gpt/gpt.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/sbin/gpt/gpt.c b/sbin/gpt/gpt.c
index 6085ed2..543acca 100644
--- a/sbin/gpt/gpt.c
+++ b/sbin/gpt/gpt.c
@@ -268,6 +268,13 @@ parse_uuid(const char *s, uuid_t *uuid)
return (0);
switch (*s) {
+ case 'b':
+ if (strcmp(s, "boot") == 0) {
+ uuid_t boot = GPT_ENT_TYPE_FREEBSD_BOOT;
+ *uuid = boot;
+ return (0);
+ }
+ break;
case 'e':
if (strcmp(s, "efi") == 0) {
uuid_t efi = GPT_ENT_TYPE_EFI;
OpenPOWER on IntegriCloud