summaryrefslogtreecommitdiffstats
path: root/lib/libdisk/chunk.c
diff options
context:
space:
mode:
authorphk <phk@FreeBSD.org>1995-05-11 05:22:54 +0000
committerphk <phk@FreeBSD.org>1995-05-11 05:22:54 +0000
commit2e780cd86fd6e41356091d32a0e60b54d737f8d3 (patch)
treec4acd58166be0977f64200c6b3779bbb24931b2f /lib/libdisk/chunk.c
parenta558882de6fc93c6cd240cfae7fbca856a958d92 (diff)
downloadFreeBSD-src-2e780cd86fd6e41356091d32a0e60b54d737f8d3.zip
FreeBSD-src-2e780cd86fd6e41356091d32a0e60b54d737f8d3.tar.gz
Get the CHUNK_COMPAT_BSD flag right.
Diffstat (limited to 'lib/libdisk/chunk.c')
-rw-r--r--lib/libdisk/chunk.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/libdisk/chunk.c b/lib/libdisk/chunk.c
index 54630be..c100927 100644
--- a/lib/libdisk/chunk.c
+++ b/lib/libdisk/chunk.c
@@ -6,7 +6,7 @@
* this stuff is worth it, you can buy me a beer in return. Poul-Henning Kamp
* ----------------------------------------------------------------------------
*
- * $Id: chunk.c,v 1.10 1995/05/07 01:28:16 jkh Exp $
+ * $Id: chunk.c,v 1.11 1995/05/08 02:08:25 phk Exp $
*
*/
@@ -200,6 +200,8 @@ Add_Chunk(struct disk *d, long offset, u_long size, char *name, chunk_e type,
c1->subtype = subtype;
return 0;
}
+ if (type == freebsd)
+ subtype = 0xa5;
c1 = 0;
if(!c1 && (type == freebsd || type == fat || type == unknown))
c1 = Find_Mother_Chunk(d->chunks,offset,end,extended);
@@ -380,6 +382,7 @@ Collapse_Chunk(struct disk *d, struct chunk *c1)
}
if(c3->type == unused) {
c2 = new_chunk();
+ if (!c2) err(1,"malloc failed");
*c2 = *c1;
c1->next = c2;
c1->name = strdup("-");
OpenPOWER on IntegriCloud