YoushouldhavereceivedacopyoftheGNUGeneralPublicLicense alongwiththisprogram;ifnot,writetotheFreeSoftware
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1335 USA */
if (!(ret= azopen(&reader_handle, argv[0], O_RDONLY|O_BINARY)))
{
printf("Could not open Archive file\n"); return0;
}
if (opt_autoincrement)
{
azio_stream writer_handle;
if (new_auto_increment_value)
{ if (reader_handle.auto_increment >= new_auto_increment_value)
{
printf("Value is lower then current value\n"); goto end;
}
} else
{
new_auto_increment_value= reader_handle.auto_increment + 1;
}
if (!(ret= azopen(&writer_handle, argv[0], O_CREAT|O_RDWR|O_BINARY)))
{
printf("Could not open file for update: %s\n", argv[0]); goto end;
}
staticstruct my_option my_long_options[] =
{
{"backup", 'b', "Make a backup of an archive table.", 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0},
{"check", 'c', "Check table for errors.", 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0}, #ifndef DBUG_OFF
{"debug", '#', "Output debug log. Often this is 'd:t:o,filename'.", 0, 0, 0, GET_STR, OPT_ARG, 0, 0, 0, 0, 0, 0}, #endif
{"extract-frm", 'e', "Extract the frm file.", 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0},
{"force", 'f', "Restart with -r if there are any errors in the table.", 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0},
{"help", '?', "Display this help and exit.", 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0},
{"quick", 'q', "Faster repair by not modifying the data file.", 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0},
{"repair", 'r', "Repair a damaged Archive version 3 or above file.", 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0},
{"set-auto-increment", 'A', "Force auto_increment to start at this or higher value. If no value is given, then sets the next auto_increment value to the highest used value for the auto key + 1.",
&new_auto_increment, &new_auto_increment, 0, GET_ULL, OPT_ARG, 0, 0, 0, 0, 0, 0},
{"silent", 's', "Only print errors. One can use two -s to make archive_reader very silent.", 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0},
{"tmpdir", 't', "Path for temporary files.",
&opt_tmpdir, 0, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0},
{"version", 'V', "Print version and exit.", 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0},
{ 0, 0, 0, 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0}
};
staticvoid usage(void)
{
print_version();
puts("Copyright 2007-2008 MySQL AB, 2008 Sun Microsystems, Inc.");
puts("This software comes with ABSOLUTELY NO WARRANTY. This is free software,\nand you are welcome to modify and redistribute it under the GPL license\n");
puts("Read and modify Archive files directly\n");
printf("Usage: %s [OPTIONS] file_to_be_looked_at [file_for_backup]\n", my_progname);
print_defaults("my", load_default_groups);
my_print_help(my_long_options);
}
¤ Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.0.13Bemerkung:
(vorverarbeitet am 2026-10-08)
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.