Changed returncodes to -1 of mount_disks in case of error (before, they were
inverted). Add message mount_failed to be displayed when a mount fails, offering the opportunity to go on anyway (fix for PR install/12020).
This commit is contained in:
parent
6a03bb6b37
commit
cb54fe064f
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: disks.c,v 1.123 2012/01/09 01:51:47 riz Exp $ */
|
||||
/* $NetBSD: disks.c,v 1.124 2012/05/21 22:38:26 jdf Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright 1997 Piermont Information Systems Inc.
|
||||
@ -805,8 +805,12 @@ foundffs(struct data *list, size_t num)
|
||||
return error;
|
||||
|
||||
error = target_mount("", list[0].u.s_val, ' '-'a', list[1].u.s_val);
|
||||
if (error != 0)
|
||||
return error;
|
||||
if (error != 0) {
|
||||
msg_display(MSG_mount_failed, list[0].u.s_val);
|
||||
process_menu(MENU_noyes, NULL);
|
||||
if (!yesno)
|
||||
return error;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -854,7 +858,9 @@ fsck_preen(const char *disk, int ptn, const char *fsname)
|
||||
free(prog);
|
||||
if (error != 0) {
|
||||
msg_display(MSG_badfs, disk, ptn, error);
|
||||
process_menu(MENU_ok, NULL);
|
||||
process_menu(MENU_noyes, NULL);
|
||||
if (yesno)
|
||||
error = 0;
|
||||
/* XXX at this point maybe we should run a full fsck? */
|
||||
}
|
||||
return error;
|
||||
@ -966,7 +972,7 @@ mount_disks(void)
|
||||
else {
|
||||
error = mount_root();
|
||||
if (error != 0 && error != EBUSY)
|
||||
return 0;
|
||||
return -1;
|
||||
}
|
||||
|
||||
/* Check the target /etc/fstab exists before trying to parse it. */
|
||||
@ -974,7 +980,7 @@ mount_disks(void)
|
||||
target_file_exists_p("/etc/fstab") == 0) {
|
||||
msg_display(MSG_noetcfstab, diskdev);
|
||||
process_menu(MENU_ok, NULL);
|
||||
return 0;
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
||||
@ -984,7 +990,7 @@ mount_disks(void)
|
||||
/* error ! */
|
||||
msg_display(MSG_badetcfstab, diskdev);
|
||||
process_menu(MENU_ok, NULL);
|
||||
return 0;
|
||||
return -1;
|
||||
}
|
||||
error = walk(fstab, (size_t)fstabsize, fstabbuf, numfstabbuf);
|
||||
free(fstab);
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: msg.mi.de,v 1.67 2012/04/30 19:49:26 martin Exp $ */
|
||||
/* $NetBSD: msg.mi.de,v 1.68 2012/05/21 22:38:25 jdf Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright 1997 Piermont Information Systems Inc.
|
||||
@ -124,6 +124,9 @@ Wollen Sie die NetBSD Distributionssets wirklich erneut installieren?
|
||||
überschrieben werden!)
|
||||
}
|
||||
|
||||
message mount_failed
|
||||
{Versuch, %s zu mounten ist fehlgeschlagen. Fortfahren?
|
||||
}
|
||||
|
||||
message nodisk
|
||||
{Ich kann keine für NetBSD nutzbaren Festplatten finden.
|
||||
@ -711,9 +714,9 @@ message makedev
|
||||
|
||||
message badfs
|
||||
{Das Dateisystem auf /dev/%s%c scheint kein BSD-Dateisystem zu sein,
|
||||
die Prüfung des Dateisystems (fsck) ist fehlgeschlagen.
|
||||
die Prüfung des Dateisystems (fsck) ist fehlgeschlagen (Fehler %d).
|
||||
|
||||
Die Aktualisierung wird abgebrochen. (Fehlernummer %d.)
|
||||
Die Aktualisierung trotzdem fortsetzen?
|
||||
}
|
||||
|
||||
message rootmissing
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: msg.mi.en,v 1.172 2012/04/06 23:48:53 riz Exp $ */
|
||||
/* $NetBSD: msg.mi.en,v 1.173 2012/05/21 22:38:25 jdf Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright 1997 Piermont Information Systems Inc.
|
||||
@ -117,6 +117,9 @@ Do you really want to reinstall NetBSD distribution sets?
|
||||
disks.)
|
||||
}
|
||||
|
||||
message mount_failed
|
||||
{Mounting %s failed. Continue?
|
||||
}
|
||||
|
||||
message nodisk
|
||||
{I can not find any hard disks for use by NetBSD. You will be
|
||||
@ -680,7 +683,7 @@ message makedev
|
||||
|
||||
message badfs
|
||||
{It appears that /dev/%s%c is not a BSD file system or the fsck was
|
||||
not successful. The upgrade has been aborted. (Error number %d.)
|
||||
not successful. Try mounting it anyway? (Error number %d.)
|
||||
}
|
||||
|
||||
message rootmissing
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: msg.mi.es,v 1.43 2012/04/06 23:48:53 riz Exp $ */
|
||||
/* $NetBSD: msg.mi.es,v 1.44 2012/05/21 22:38:25 jdf Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright 1997 Piermont Information Systems Inc.
|
||||
@ -124,6 +124,9 @@ ninguna informaci
|
||||
sus discos.)
|
||||
}
|
||||
|
||||
message mount_failed
|
||||
{Mounting %s failed. Continue?
|
||||
}
|
||||
|
||||
message nodisk
|
||||
{No se ha podido encontrar ningún disco duro para ser usado por NetBSD.
|
||||
@ -701,7 +704,7 @@ message makedev
|
||||
|
||||
message badfs
|
||||
{Parece que /dev/%s%c no es un sistema de archivos BSD o el fsck no ha sido
|
||||
correcto. La actualización ha sido interrumpida. (Error número %d.)
|
||||
correcto. ¿Continuar? (Error número %d.)
|
||||
}
|
||||
|
||||
message rootmissing
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: msg.mi.fr,v 1.126 2012/04/08 03:11:14 uebayasi Exp $ */
|
||||
/* $NetBSD: msg.mi.fr,v 1.127 2012/05/21 22:38:26 jdf Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright 1997 Piermont Information Systems Inc.
|
||||
@ -127,6 +127,10 @@ Voulez-vous r
|
||||
modifier vos disques).
|
||||
}
|
||||
|
||||
message mount_failed
|
||||
{Le montage du système de fichiers %s a échoué. Continuer ?
|
||||
}
|
||||
|
||||
message nodisk
|
||||
{Aucun disque utilisable par NetBSD n'a été trouvé.
|
||||
Retour au menu précédent.
|
||||
@ -748,9 +752,9 @@ message makedev
|
||||
message badfs
|
||||
{
|
||||
/dev/%s%c ne semble pas être un système de fichiers BSD, ou
|
||||
la vérification de son intégrité par fsck a échoué.
|
||||
la vérification de son intégrité par fsck a échoué, code d'erreur %d.
|
||||
|
||||
Interruption de la procédure de mise à jour, code d'erreur %d.
|
||||
Souhaitez-vous continuer mise à jour?
|
||||
}
|
||||
|
||||
message rootmissing
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: msg.mi.pl,v 1.83 2012/04/06 23:48:53 riz Exp $ */
|
||||
/* $NetBSD: msg.mi.pl,v 1.84 2012/05/21 22:38:26 jdf Exp $ */
|
||||
/* Based on english version: */
|
||||
/* NetBSD: msg.mi.pl,v 1.36 2004/04/17 18:55:35 atatat Exp */
|
||||
|
||||
@ -121,6 +121,10 @@ Czy napewno chcesz przeinstalowac pakiety dystrybucjne NetBSD?
|
||||
twoich dyskach.)
|
||||
}
|
||||
|
||||
message mount_failed
|
||||
{Mounting %s failed. Continue?
|
||||
}
|
||||
/* XXX: Translate. */
|
||||
|
||||
message nodisk
|
||||
{Nie moge znalezc zadnych twardych dyskow do uzycia z NetBSD. Zostaniesz
|
||||
@ -675,6 +679,10 @@ message makedev
|
||||
{Tworzenie plikow urzadzen ...
|
||||
}
|
||||
|
||||
/* XXX: Translate:
|
||||
* -not successful. The upgrade has been aborted. (Error number %d.)
|
||||
* +not successful (Error number %d.). Try mounting it anyway?
|
||||
*/
|
||||
message badfs
|
||||
{Wyglada na to, ze /dev/%s%c nie jest systemem plikow BSD albo nie powiodlo sie
|
||||
jego sprawdzenie. Aktualizacja zostala przerwana. (Blad numer %d.)
|
||||
|
Loading…
Reference in New Issue
Block a user