diff options
-rw-r--r-- | src/patchelf.cc | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/patchelf.cc b/src/patchelf.cc index 126cada..859fe92 100644 --- a/src/patchelf.cc +++ b/src/patchelf.cc @@ -477,6 +477,8 @@ static void writeFile(const std::string & fileName, const FileContents & content static uint64_t roundUp(uint64_t n, uint64_t m) { + if (n == 0) + return m; return ((n - 1) / m + 1) * m; } |