summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorMichael Smith <mikesmiffy128@gmail.com>2022-05-25 23:30:32 +0100
committerMichael Smith <mikesmiffy128@gmail.com>2022-05-25 23:30:32 +0100
commit268e09ecd101cf235fd9056bd1d5ab3d0a3c58fb (patch)
treedf13284e5f01e264c1b9f931abbc600dd795c937
parentc83de76ad2f59927cf01bcfbae18a5d598159bb7 (diff)
Fix wonky comparisons in CreateInterface
A stupid, stupid bug I'd probably never have caught for years and years. Thanks Evan Lin in the Portal Discord for pointing it out!
-rw-r--r--src/sst.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/sst.c b/src/sst.c
index 554cfe5..293a6b4 100644
--- a/src/sst.c
+++ b/src/sst.c
@@ -484,7 +484,7 @@ static const void *const *const plugin_obj = vtable;
EXPORT const void *CreateInterface(const char *name, int *ret) {
if (!strncmp(name, "ISERVERPLUGINCALLBACKS00", 24)) {
- if ((name[24] >= '1' || name[24] <= '3') && name[25] == '\0') {
+ if (name[24] >= '1' && name[24] <= '3' && name[25] == '\0') {
if (ret) *ret = 0;
ifacever = name[24] - '0';
return &plugin_obj;