merge trunk

This commit is contained in:
Szymon Janc 2011-08-20 20:21:36 +02:00
commit 9e07f21128
2 changed files with 15 additions and 1 deletions

View file

@ -1,3 +1,10 @@
2011-08-20 Szymon Janc <szymon@janc.net.pl>
Add grub-fstest option to uncompress data for commands.
* util/grub-fstest.c (uncompress): New var.
(options): New option -u.
2011-08-20 Szymon Janc <szymon@janc.net.pl>
* grub-core/loader/i386/linux.c (grub_linux_setup_video): Add

View file

@ -68,6 +68,7 @@ enum {
#define BUF_SIZE 32256
static grub_disk_addr_t skip, leng;
static int uncompress = 0;
static void
read_file (char *pathname, int (*hook) (grub_off_t ofs, char *buf, int len))
@ -111,7 +112,8 @@ read_file (char *pathname, int (*hook) (grub_off_t ofs, char *buf, int len))
return;
}
grub_file_filter_disable_compression ();
if (uncompress == 0)
grub_file_filter_disable_compression ();
file = grub_file_open (pathname);
if (!file)
{
@ -409,6 +411,7 @@ static struct argp_option options[] = {
{"debug", 'd', "S", 0, N_("Set debug environment variable."), 2},
{"crypto", 'C', NULL, OPTION_ARG_OPTIONAL, N_("Mount crypto devices."), 2},
{"verbose", 'v', NULL, OPTION_ARG_OPTIONAL, N_("Print verbose messages."), 2},
{"uncompress", 'u', NULL, OPTION_ARG_OPTIONAL, N_("Uncompress data."), 2},
{0, 0, 0, 0, 0, 0}
};
@ -469,6 +472,10 @@ argp_parser (int key, char *arg, struct argp_state *state)
verbosity++;
return 0;
case 'u':
uncompress = 1;
return 0;
case ARGP_KEY_END:
if (args_count < num_disks)
{