aboutsummaryrefslogtreecommitdiffstats
path: root/src/brice.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/brice.cpp')
-rw-r--r--src/brice.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/brice.cpp b/src/brice.cpp
index 5e7237f..53b1431 100644
--- a/src/brice.cpp
+++ b/src/brice.cpp
@@ -58,9 +58,9 @@ namespace game {
}
void briceLoad(void) {
- const char *data = readFile("brice.dat");
+ auto data = readFile("brice.dat");
- if (data == nullptr) {
+ if (data.empty()) {
briceClear();
data = readFile("brice.dat");
}
@@ -74,8 +74,6 @@ namespace game {
brice.emplace(std::make_pair(datas[i], datas[i + 1]));
}
}
-
- delete[] data;
}
void briceUpdate(void) {