Handle symlinks and long names on tar and cpio.

* grub-core/fs/cpio.c (ATTR_TYPE): New definition.
	(ATTR_FILE): Likewise.
	(ATTR_DIR): Likewise.
	(ATTR_LNK): Likewise.
	(grub_cpio_data) [MODE_USTAR]: New fields linkname and linkname_alloc.
	(grub_cpio_find_file): Fill mode, handle linkname field as well as
	L and K entries.
	(grub_cpio_mount): Zero-fill data.
	(handle_symlink): New function.
This commit is contained in:
Vladimir 'phcoder' Serbinenko 2011-10-30 23:06:25 +01:00
parent c83a08d84a
commit 19ee298767
2 changed files with 307 additions and 58 deletions

View file

@ -1,3 +1,17 @@
2011-10-30 Vladimir Serbinenko <phcoder@gmail.com>
Handle symlinks and long names on tar and cpio.
* grub-core/fs/cpio.c (ATTR_TYPE): New definition.
(ATTR_FILE): Likewise.
(ATTR_DIR): Likewise.
(ATTR_LNK): Likewise.
(grub_cpio_data) [MODE_USTAR]: New fields linkname and linkname_alloc.
(grub_cpio_find_file): Fill mode, handle linkname field as well as
L and K entries.
(grub_cpio_mount): Zero-fill data.
(handle_symlink): New function.
2011-10-30 Vladimir Serbinenko <phcoder@gmail.com>
Fix iso9660 filename limitations and fix memory leaks.