char green_broadcast[STRING_SIZE];
char root_password[STRING_SIZE];
char admin_password[STRING_SIZE];
- char restore_file[STRING_SIZE];
+ char restore_file[STRING_SIZE] = "";
findkey(unattendedkv, "DOMAINNAME", domainname);
findkey(unattendedkv, "HOSTNAME", hostname);
}
/* restore backup */
- if (!strcmp(restore_file, "")) {
+ if (strlen(restore_file) > 0) {
fprintf(flog, "unattended: Restoring Backup\n");
snprintf(commandstring, STRING_SIZE,
- "cd /harddisk && /bin/tar -xvz --preserve -f /cdrom/%s", restore_file);
+ "cd /harddisk && /bin/tar -xvzp -f /harddisk/var/ipfire/backup/%s", restore_file);
if (mysystem(commandstring)) {
- errorbox("unattended: ERROR restoring backup");
- return 0;
+ errorbox("unattended: ERROR restoring backup");
}
}