aboutsummaryrefslogtreecommitdiff
path: root/weed/filesys/page_writer.go
diff options
context:
space:
mode:
authorchrislu <chris.lu@gmail.com>2021-12-23 17:48:34 -0800
committerchrislu <chris.lu@gmail.com>2021-12-23 17:48:34 -0800
commitf77ca41769b8466cec64c39767e0fcc038f51b31 (patch)
tree83c489bc349180dfcf5e238c235c966808133152 /weed/filesys/page_writer.go
parent1d36884845d60d37897c13f14923b80cf2c94e29 (diff)
downloadseaweedfs-f77ca41769b8466cec64c39767e0fcc038f51b31.tar.xz
seaweedfs-f77ca41769b8466cec64c39767e0fcc038f51b31.zip
refactor
Diffstat (limited to 'weed/filesys/page_writer.go')
-rw-r--r--weed/filesys/page_writer.go13
1 files changed, 13 insertions, 0 deletions
diff --git a/weed/filesys/page_writer.go b/weed/filesys/page_writer.go
index 8e52f9f67..560ae052d 100644
--- a/weed/filesys/page_writer.go
+++ b/weed/filesys/page_writer.go
@@ -92,3 +92,16 @@ func (pw *PageWriter) GetStorageOptions() (collection, replication string) {
func (pw *PageWriter) Destroy() {
pw.randomWriter.Destroy()
}
+
+func max(x, y int64) int64 {
+ if x > y {
+ return x
+ }
+ return y
+}
+func min(x, y int64) int64 {
+ if x < y {
+ return x
+ }
+ return y
+}