Mercurial > hg > orthanc
diff OrthancFramework/Sources/FileStorage/FilesystemStorage.cpp @ 5374:b216b57bbe6a
more detailed logs
author | Alain Mazy <am@osimis.io> |
---|---|
date | Tue, 22 Aug 2023 12:30:05 +0200 |
parents | 0ea402b4d901 |
children | b83192e7ad10 |
line wrap: on
line diff
--- a/OrthancFramework/Sources/FileStorage/FilesystemStorage.cpp Thu Aug 17 17:25:08 2023 +0200 +++ b/OrthancFramework/Sources/FileStorage/FilesystemStorage.cpp Tue Aug 22 12:30:05 2023 +0200 @@ -122,8 +122,16 @@ size_t size, FileContentType type) { - LOG(INFO) << "Creating attachment \"" << uuid << "\" of \"" << GetDescriptionInternal(type) - << "\" type (size: " << (size / (1024 * 1024) + 1) << "MB)"; + if (size > (1024 * 1024)) + { + LOG(INFO) << "Creating attachment \"" << uuid << "\" of \"" << GetDescriptionInternal(type) + << "\" type (size: " << (size / (1024 * 1024) + 1) << "MB)"; + } + else + { + LOG(INFO) << "Creating attachment \"" << uuid << "\" of \"" << GetDescriptionInternal(type) + << "\" type (size: " << (size / 1024 + 1) << "KB)"; + } boost::filesystem::path path;