Index: openacs-4/packages/file-storage/tcl/file-storage-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/file-storage/tcl/file-storage-procs.tcl,v diff -u -N -r1.90.2.3 -r1.90.2.4 --- openacs-4/packages/file-storage/tcl/file-storage-procs.tcl 15 Apr 2019 13:24:59 -0000 1.90.2.3 +++ openacs-4/packages/file-storage/tcl/file-storage-procs.tcl 23 Jun 2019 16:51:26 -0000 1.90.2.4 @@ -1713,7 +1713,9 @@ [lindex [ns_driver names] 0]}] set section [ns_driversection -driver $driver] set max_bytes_conf [ns_config $section maxinput] - + if {[regexp {^([0-9.]+)(MB|KB)} $max_bytes_conf . number unit]} { + set max_bytes_conf [expr {int($number * ($unit eq "BB" ? 1024 : 1024*1024))}] + } return [expr {min($max_bytes_param,$max_bytes_conf)}] }