fix(connection): Make bytes up and down a signed 64-bit integer

This fixes a theoretical issue with database interaction. Because the
fields in the database are signed 64-bit integers, it's theoretically
possible to overflow them if we're using unsigned 64-bit integers in the
application code.
This commit is contained in:
Hugo Vieira committed 2022-10-26 17:44:28 +01:00
1 parent c81398cbf3
commit d206635d74
17 files changed
+57 -57

No files matched your search

@@ -33,10 +33,10 @@ message Connection {
uint32 endpoint_tcp_port = 6; // @gotags: `class:"public"`
// bytes_up of the connection
uint64 bytes_up = 7; // @gotags: `class:"public"`
int64 bytes_up = 7; // @gotags: `class:"public"`
// bytes_down of the connection
uint64 bytes_down = 8; // @gotags: `class:"public"`
int64 bytes_down = 8; // @gotags: `class:"public"`
// closed_reason of the connection
string closed_reason = 9; // @gotags: `class:"public"`