lkml.org 
[lkml]   [2008]   [Jan]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: [ANNOUNCE] Btrfs v0.10 (online growing/shrinking, ext3 conversion, and more)
On Tue, Jan 15, 2008 at 10:52:38AM -0500, Chris Mason wrote:
> http://oss.oracle.com/projects/btrfs/
>
> Btrfs is still in an early alpha state, and the disk format is not finalized.
> v0.10 introduces a new disk format, and is not compatible with v0.9.
>

Looks like fun. btrfsck fails to check if it actually received a
dev argument though, so if you don't pass a device, we get a nice
segfault.

Signed-off-by: Kyle McMartin <kmcmartin@redhat.com>

---
diff -Nur btrfs-progs-0.10/btrfsck.c btrfs-progs-0.10-kyle/btrfsck.c
--- btrfs-progs-0.10/btrfsck.c 2008-01-15 10:33:32.000000000 -0500
+++ btrfs-progs-0.10-kyle/btrfsck.c 2008-01-15 11:49:24.000000000 -0500
@@ -709,6 +709,11 @@
return err;
}

+void print_usage(void) {
+ fprintf(stderr, "usage: btrfsck dev\n");
+ exit(1);
+}
+
int main(int ac, char **av) {
struct btrfs_root *root;
struct cache_tree extent_cache;
@@ -727,6 +732,9 @@
int slot;
struct btrfs_root_item ri;

+ if (ac < 2)
+ print_usage();
+
radix_tree_init();
cache_tree_init(&extent_cache);
cache_tree_init(&seen);

\
 
 \ /
  Last update: 2008-01-15 18:09    [from the cache]
©2003-2014 Jasper Spaans. Advertise on this site