1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
--- ./bsnes/ui/tools/state-manager.cpp.orig
+++ ./bsnes/ui/tools/state-manager.cpp
@@ -135,7 +135,7 @@
string StateManager::slotLoadDescription(unsigned n) {
if(slot[n].capacity() == 0) return "(empty)";
char text[DescriptionLength];
- strlcpy(text, (const char*)slot[n].data() + HeaderLength, DescriptionLength);
+ nall::strlcpy(text, (const char*)slot[n].data() + HeaderLength, DescriptionLength);
return text;
}
@@ -143,7 +143,7 @@
if(stateList.selected() == false) return;
string text = descEdit.text();
if(slot[stateList.selection()].capacity() > 0) {
- strlcpy((char*)slot[stateList.selection()].data() + HeaderLength, (const char*)text, DescriptionLength);
+ nall::strlcpy((char*)slot[stateList.selection()].data() + HeaderLength, (const char*)text, DescriptionLength);
}
refresh();
}
--- ./bsnes/snes/system/serialization.cpp.orig
+++ ./bsnes/snes/system/serialization.cpp
@@ -7,7 +7,7 @@
char description[512], profile[16];
memset(&description, 0, sizeof description);
memset(&profile, 0, sizeof profile);
- strlcpy(profile, Info::Profile, sizeof profile);
+ nall::strlcpy(profile, Info::Profile, sizeof profile);
s.integer(signature);
s.integer(version);
|