int confirm_retention(UAContext *ua, utime_t *ret, const char *msg)
{
char ed1[100];
+ int val;
for ( ;; ) {
bsendmsg(ua, _("The current %s retention period is: %s\n"),
}
continue;
}
- if (strcasecmp(ua->cmd, _("yes")) == 0) {
- return 1;
- }
- if (strcasecmp(ua->cmd, _("no")) == 0) {
- return 0;
+ if (is_yesno(ua->cmd, &val)) {
+ return val; /* is 1 for yes, 0 for no */
}
}
return 1;
bsendmsg(ua, _("JobId %s is not running.\n"), edit_int64(jobid, ed1));
return NULL;
}
- store = jcr->store;
+ store = jcr->wstore;
free_jcr(jcr);
break;
bsendmsg(ua, _("Job \"%s\" is not running.\n"), ua->argv[i]);
return NULL;
}
- store = jcr->store;
+ store = jcr->wstore;
free_jcr(jcr);
break;
} else if (strcasecmp(ua->argk[i], NT_("ujobid")) == 0) {
bsendmsg(ua, _("Job \"%s\" is not running.\n"), ua->argv[i]);
return NULL;
}
- store = jcr->store;
+ store = jcr->wstore;
free_jcr(jcr);
break;
}