lkml.org 
[lkml]   [2006]   [Mar]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] initramfs: CPIO unpacking fix
Michael Neuling wrote:
> Unlink files, symlinks, FIFOs, devices etc. (except directories) before
> writing them when extracting CPIOs. This stops weird behaviour like:
> 1) writing through symlinks created in earlier CPIOs. eg foo->bar in
> the first CPIO. Having foo as a non-link in a subsequent CPIO,
> results in bar being written and foo remaining as a symlink.
> 2) if the first version of file foo is larger than foo in a
> subsequent CPIO, we end up with a mix of the two. ie. neither
> the first or second version of /foo.
> 3) special files like devices, fifo etc. can't be overwritten in
> subsequent CPIOS.
>
> With this, the kernel will more closely replicate
> for i in *.cpio; do cpio --extract --unconditional < $i ; done
>
> This is a change but it's regarded as fixing broken functionality.
>
> Signed-off-by: Michael Neuling <mikey@neuling.org>

For the kernel, I would regard that as needless code... Coding for a
chain of CPIO archives overwriting each other seems like overengineering.

Jeff



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2006-03-22 08:16    [W:0.966 / U:0.000 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site