8000 Fix conditional · coder/coder@b34e9d8 · GitHub
[go: up one dir, main page]

Skip to content

Commit b34e9d8

Browse files
committed
Fix conditional
1 parent 47e3480 commit b34e9d8

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

provisionersdk/archive.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ func Tar(w io.Writer, directory string, limit int64) error {
9797
return nil
9898
}
9999
// Before we even open the file, check if it is going to exceed our limit.
100-
if fileInfo.Size()+totalSize >= limit {
100+
if fileInfo.Size()+totalSize > limit {
101101
return fileTooBigError
102102
}
103103
data, err := os.Open(file)
@@ -110,7 +110,7 @@ func Tar(w io.Writer, directory string, limit int64) error {
110110
return err
111111
}
112112
totalSize += wrote
113-
if limit != 0 && totalSize >= limit {
113+
if limit != 0 && totalSize > limit {
114114
return fileTooBigError
115115
}
116116
return data.Close()

0 commit comments

Comments
 (0)
0