diff --git a/config.json b/config.json index fa95be9..331a931 100644 --- a/config.json +++ b/config.json @@ -4,13 +4,6 @@ "address": "0.0.0.0", "port": 80, "https": false - }, - { - "address": "0.0.0.0", - "port": 443, - "https": true, - "cert": "", - "key": "" } ] } diff --git a/include/log.hpp b/include/log.hpp index d8aa642..838d4a3 100644 --- a/include/log.hpp +++ b/include/log.hpp @@ -11,7 +11,7 @@ struct Log void AddTrans(Transaction &&v) { end += (end < max_log_size); //branchless - if (data.size() <= end && end < max_log_size) //if memory reserved is full and max isnt reached + if (data.size() == end && end < max_log_size) //if memory reserved is full and max isnt reached { if (data.size() + pre_log_size > max_log_size) //if prefetched memory is larger then max { diff --git a/users.json b/users.json index 2c63c08..d30fc31 100644 --- a/users.json +++ b/users.json @@ -1,2 +1,42 @@ { -} + "jolly" : + { + "balance" : 2024, + "log" : + [ + { + "amount" : 2, + "from" : "twix", + "time" : 1622711963204, + "to" : "jolly" + }, + { + "amount" : 1, + "from" : "twix", + "time" : 1622711903088, + "to" : "jolly" + } + ], + "password" : 746744014776526199 + }, + "twix" : + { + "balance" : 97976, + "log" : + [ + { + "amount" : 2, + "from" : "twix", + "time" : 1622711963204, + "to" : "jolly" + }, + { + "amount" : 1, + "from" : "twix", + "time" : 1622711903088, + "to" : "jolly" + } + ], + "password" : 746744014776526199 + } +} \ No newline at end of file