do not check size if MaxSize == 0
This commit is contained in:
parent
74a9a408e6
commit
04d559dd47
|
@ -155,7 +155,7 @@ func (handler *Handler) postFile(w http.ResponseWriter, r *http.Request) {
|
|||
}
|
||||
|
||||
// Test whether the size is still allowed
|
||||
if size > handler.config.MaxSize {
|
||||
if handler.config.MaxSize > 0 && size > handler.config.MaxSize {
|
||||
handler.sendError(w, ErrMaxSizeExceeded)
|
||||
return
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue