]> andersk Git - moira.git/blobdiff - gen/zero_quotas
Command line printer manipulation client, and build goo.
[moira.git] / gen / zero_quotas
index 14cba8f5bcfe856b7f138561fa57b0fafadd381c..ee7f001ace2f2f52cb6b8e810abc8225ad1a070f 100644 (file)
@@ -6,7 +6,7 @@
 # Note that the input must be sorted in increasing order by uid.
 
 set dev=$1
-set SMS_SETQUOTA = 47836471
+set MR_SETQUOTA = 47836471
 
 # Checking for /etc/zero_old_quotas allows us to release this program
 # one server at a time.
@@ -18,31 +18,31 @@ if ( -f /etc/zero_old_quotas ) then
    while (1)
       # set args = $< will NOT work.  $< will be treated as a single word
       set args = `echo $<`
+
       if (${#args} != 2) break   # end of input
 
       set uid = $args[1]
       @ checksorted = ($current_uid <= $uid)
 
-      if (checksorted == 0) then 
+      if (checksorted == 0) then
        echo "Input not sorted"
-       exit $SMS_SETQUOTA
+       exit $MR_SETQUOTA
       endif
 
       # zero all quotas between current_uid and uid (not including uid)
       if ($current_uid != $uid) then
        @ uid_high = $uid - 1
-        setquota -r $dev $current_uid $uid_high $2
+        setquota -r $dev $current_uid $uid_high 0
       endif
 
      # skip over $uid
      @ current_uid = $uid + 1
 
    end
-  
+
    # zero all remaining quotas, except for nobody (32767).
-   if ($current_uid != 32767) setquota -r $dev $current_uid 32766 $2
-   
+   if ($current_uid != 32767) setquota -r $dev $current_uid 32766 0
+
 endif
 
 exit 0
This page took 0.0848989999999999 seconds and 4 git commands to generate.