From 2f4e4e448fb34773728c0e2ef93be8d456a039cb Mon Sep 17 00:00:00 2001 From: Ilya Dryomov Date: Tue, 12 Feb 2013 21:24:50 +0200 Subject: Btrfs-progs: move crc32c optimization init Don't call crc32c_optimization_init() until we know that a command is actually going to be invoked. Signed-off-by: Ilya Dryomov --- btrfs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/btrfs.c b/btrfs.c index 1852a217..062bc515 100644 --- a/btrfs.c +++ b/btrfs.c @@ -263,8 +263,6 @@ int main(int argc, char **argv) { const struct cmd_struct *cmd; - crc32c_optimization_init(); - argc--; argv++; handle_options(&argc, &argv); @@ -280,6 +278,8 @@ int main(int argc, char **argv) handle_help_options_next_level(cmd, argc, argv); + crc32c_optimization_init(); + fixup_argv0(argv, cmd->token); exit(cmd->fn(argc, argv)); } -- cgit v1.2.3