diff --git a/ChangeLog b/ChangeLog index 20755417b4..1064db459f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Fri Apr 13 10:00:04 CEST 2007 Daniel Veillard + + * src/virsh.c: fixed a bad messaging mechanism preventing localization + and raised by Thomas Canniot + Thu Apr 12 19:51:00 EST 2007 Daniel Berrange * src/xen_internal.c: Updated structs to work with new Xen 3.0.5 diff --git a/src/virsh.c b/src/virsh.c index 8237e93a84..4ad428c6b0 100644 --- a/src/virsh.c +++ b/src/virsh.c @@ -327,14 +327,20 @@ cmdAutostart(vshControl * ctl, vshCmd * cmd) autostart = !vshCommandOptBool(cmd, "disable"); if (virDomainSetAutostart(dom, autostart) < 0) { - vshError(ctl, FALSE, _("Failed to %smark domain %s as autostarted"), - autostart ? "" : "un", name); + if (autostart) + vshError(ctl, FALSE, _("Failed to mark domain %s as autostarted"), + name); + else + vshError(ctl, FALSE, _("Failed to unmark domain %s as autostarted"), + name); virDomainFree(dom); return FALSE; } - vshPrint(ctl, _("Domain %s %smarked as autostarted\n"), - name, autostart ? "" : "un"); + if (autostart) + vshPrint(ctl, _("Domain %s marked as autostarted\n"), name); + else + vshPrint(ctl, _("Domain %s unmarked as autostarted\n"), name); return TRUE; } @@ -1754,14 +1760,20 @@ cmdNetworkAutostart(vshControl * ctl, vshCmd * cmd) autostart = !vshCommandOptBool(cmd, "disable"); if (virNetworkSetAutostart(network, autostart) < 0) { - vshError(ctl, FALSE, _("Failed to %smark network %s as autostarted"), - autostart ? "" : "un", name); + if (autostart) + vshError(ctl, FALSE, _("failed to mark network %s as autostarted"), + name); + else + vshError(ctl, FALSE,_("failed to unmark network %s as autostarted"), + name); virNetworkFree(network); return FALSE; } - vshPrint(ctl, _("Network %s %smarked as autostarted\n"), - name, autostart ? "" : "un"); + if (autostart) + vshPrint(ctl, _("Network %s marked as autostarted\n"), name); + else + vshPrint(ctl, _("Network %s unmarked as autostarted\n"), name); return TRUE; }