From: paulr Date: Thu, 22 Jul 2010 23:57:44 +0000 (+1000) Subject: cant remember? X-Git-Url: http://git.pjr.cc/?a=commitdiff_plain;h=refs%2Fheads%2Fmaster;p=php-bacula-disk-changer.git cant remember? --- diff --git a/bin/pbdc.php b/bin/pbdc.php index abc23ea..6649e0a 100644 --- a/bin/pbdc.php +++ b/bin/pbdc.php @@ -374,6 +374,8 @@ function add_disk() $max = (int)($disk[$i]["size"]/$ts); $kt = (int)(readline("No of tapes to create [max:$max] @ ".$ts."gb each:")); + if($kt == "") $kt = $max; + if($kt < 0) $kt = $max; if($kt > $max) { echo "Sorry, max number of tapes is $max, creating $max instead\n"; $kt = $max;