From: Kern Sibbald Date: Sat, 4 Aug 2018 14:49:32 +0000 (+0200) Subject: Fix bug #2392 again -- slot limited to pool maxvols X-Git-Tag: Release-9.2.1~25 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=97a2694cdad8fa3bb8467e417303a5e9d4fa8c7c;p=thirdparty%2Fbacula.git Fix bug #2392 again -- slot limited to pool maxvols --- diff --git a/bacula/src/dird/ua_update.c b/bacula/src/dird/ua_update.c index 3c6fd790c3..9205952082 100644 --- a/bacula/src/dird/ua_update.c +++ b/bacula/src/dird/ua_update.c @@ -309,10 +309,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); - return; + if (mr->Slot < 0) { + ua->error_msg(_("Invalid slot, it must be greater than zero\n")); } /* * Make sure to use db_update... rather than doing this directly,