]> source.dussan.org Git - gitea.git/commitdiff
Log: Ensure FLAGS=none is -1 (#9287)
authorzeripath <art27@cantab.net>
Sun, 8 Dec 2019 04:36:47 +0000 (04:36 +0000)
committertechknowlogick <techknowlogick@gitea.io>
Sun, 8 Dec 2019 04:36:47 +0000 (23:36 -0500)
modules/log/flags.go

index 992fc62ddb6e8c59fafbad23e0931df51353bb90..95950548ece7e441b40d6c05923131aa55d80e23 100644 (file)
@@ -60,5 +60,8 @@ func FlagsFromString(from string) int {
                        flags |= f
                }
        }
+       if flags == 0 {
+               return -1
+       }
        return flags
 }