Count size in signed 64-bit integers

This commit is contained in:
2025-12-17 13:43:23 +02:00
parent f98760d1dd
commit 2a7c6ce5d9
5 changed files with 24 additions and 32 deletions
+3 -3
View File
@@ -28,8 +28,8 @@ type BPMDatabase struct {
type BPMDatabaseEntry struct {
Info *PackageInfo `yaml:"info"`
Filepath string `yaml:"filepath"`
DownloadSize uint64 `yaml:"download_size"`
InstalledSize uint64 `yaml:"installed_size"`
DownloadSize int64 `yaml:"download_size"`
InstalledSize int64 `yaml:"installed_size"`
Database *BPMDatabase
}
@@ -400,7 +400,7 @@ func (entry *BPMDatabaseEntry) CreateReadableInfo(rootDir string, humanReadableS
ret = append(ret, "Installation Reason: "+installationReasonString)
}
if entry.Info.Type == "binary" {
installedSize := int64(entry.InstalledSize)
installedSize := entry.InstalledSize
var installedSizeStr string
if humanReadableSize {
installedSizeStr = bytesToHumanReadable(installedSize)