diff options
Diffstat (limited to 'main.cc')
-rw-r--r-- | main.cc | 15 |
1 files changed, 12 insertions, 3 deletions
@@ -92,7 +92,14 @@ bool delete_output_on_interrupt = false; void show_help() { std::printf( "%s - Data recovery tool and decompressor for the lzip format.\n", Program_name ); - std::printf( "\nUsage: %s [options] [files]\n", invocation_name ); + std::printf( "Lziprecover can repair perfectly most files with small errors (up to one\n" + "single-byte error per member), without the need of any extra redundance\n" + "at all. Losing an entire archive just because of a corrupt byte near the\n" + "beginning is a thing of the past.\n" + "Lziprecover can also produce a correct file by merging the good parts of\n" + "two or more damaged copies, extract data from damaged files, decompress\n" + "files and test integrity of files.\n" + "\nUsage: %s [options] [files]\n", invocation_name ); std::printf( "\nOptions:\n" " -h, --help display this help and exit\n" " -V, --version output version information and exit\n" @@ -304,10 +311,12 @@ void close_and_set_permissions( const struct stat * const in_statsp ) std::string insert_fixed( std::string name ) { - if( name.size() > 4 && name.compare( name.size() - 4, 4, ".tlz" ) == 0 ) - name.insert( name.size() - 4, "_fixed" ); + if( name.size() > 7 && name.compare( name.size() - 7, 7, ".tar.lz" ) == 0 ) + name.insert( name.size() - 7, "_fixed" ); else if( name.size() > 3 && name.compare( name.size() - 3, 3, ".lz" ) == 0 ) name.insert( name.size() - 3, "_fixed" ); + else if( name.size() > 4 && name.compare( name.size() - 4, 4, ".tlz" ) == 0 ) + name.insert( name.size() - 4, "_fixed" ); else name += "_fixed.lz"; return name; } |