Date: Sat, 18 Aug 2007 18:18:44 -0700 From: Tim Kientzle <tim@kientzle.com> To: Joerg Sonnenberger <joerg@britannica.bec.de>, "'freebsd-current@freebsd.org'" <freebsd-current@freebsd.org> Subject: RFC: #mtree signature Message-ID: <46C79A74.9050703@kientzle.com>
next in thread | raw e-mail | index | archive | help
I'm experimenting with having bsdtar able to read mtree files and convert them into tar archives. This works quite well, although there is one stumbling block: libarchive likes to auto-detect formats and the current mtree format lacks any mandatory leading signature. Any concerns or thoughts about the following patch, which simply adds "#mtree" as the first line of every mtree file? I would also, of course, like to: * add this signature to the FreeBSD /etc/mtree/ files as a first step towards getting this convention to be more widely adopted and used, * update /etc/magic to reflect this convention, * get this added to NetBSD's "mtree" utility. Tim Kientzle Index: create.c =================================================================== RCS file: /usr/cvs/FreeBSD-CVS/src/usr.sbin/mtree/create.c,v retrieving revision 1.37 diff -u -r1.37 create.c --- create.c 29 Mar 2005 11:44:17 -0000 1.37 +++ create.c 18 Aug 2007 23:52:06 -0000 @@ -87,6 +87,7 @@ char dot[] = "."; int indent = 0; + (void)printf("#mtree\n"); if (!nflag) { (void)time(&cl); (void)gethostname(host, sizeof(host));
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?46C79A74.9050703>