From 51d12497eac8b8e6f7cc33bd44e6fd976069269e Mon Sep 17 00:00:00 2001 From: Kern Sibbald Date: Mon, 15 Feb 2016 19:18:34 +1000 Subject: [PATCH] Fix update Volume=x Slot=nn when Slot > MaxVols --- bacula/src/dird/ua_update.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/bacula/src/dird/ua_update.c b/bacula/src/dird/ua_update.c index fdfe7d74ca..9d1a1707f6 100644 --- a/bacula/src/dird/ua_update.c +++ b/bacula/src/dird/ua_update.c @@ -291,9 +291,8 @@ static void update_volslot(UAContext *ua, char *val, MEDIA_DBR *mr) return; } mr->Slot = atoi(val); - if (pr.MaxVols > 0 && mr->Slot > (int)pr.MaxVols) { - ua->error_msg(_("Invalid slot, it must be between 0 and MaxVols=%d\n"), - pr.MaxVols); + if (mr->Slot < 0) { + ua->error_msg(_("Invalid slot, it must be greater than zero\n")); return; } /* -- 2.39.5