summaryrefslogtreecommitdiff
path: root/protocols/Dummy/src
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2025-04-14 13:54:00 +0300
committerGeorge Hazan <george.hazan@gmail.com>2025-04-14 13:54:00 +0300
commitf860d13465dfb6e1fb8a480d3131c51c1dd9e668 (patch)
treee59ae5d6c7c6d5752c76431cdfec2d75e622768d /protocols/Dummy/src
parent9810f9fc412bbbde03a719867dec86dd0a89b132 (diff)
fixes #4982 (Dummy: при преобразовании учётки в Dummy-учётку, выставляется Custom протокол, а не реальный)
Diffstat (limited to 'protocols/Dummy/src')
-rw-r--r--protocols/Dummy/src/dummy_proto.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/protocols/Dummy/src/dummy_proto.cpp b/protocols/Dummy/src/dummy_proto.cpp
index c2acbabc3e..55b4e9f224 100644
--- a/protocols/Dummy/src/dummy_proto.cpp
+++ b/protocols/Dummy/src/dummy_proto.cpp
@@ -104,9 +104,12 @@ int CDummyProto::getTemplateId()
if (id >= 0 && id < _countof(templates))
return id;
- CMStringA szProto(getMStringA("AM_BaseProto"));
+ CMStringA szProto(getMStringA("AM_PrevProto"));
+ if (szProto.IsEmpty())
+ szProto = getMStringA("AM_BaseProto");
+
for (auto &it : templates)
- if (!stricmp(it.name, szProto))
+ if (szProto == it.name)
return int(&it - templates);
return 0;