[Kde-bindings] KDE/kdebindings/smoke
Arno Rehn
kde at arnorehn.de
Wed Dec 10 19:39:22 UTC 2008
SVN commit 895455 by arnorehn:
* Check for icur being 0 - otherwise strcmp could
get a 0 const char* and crash. Fixes bug reported
by Eric Butler. Thanks!
CCMAIL: kde-bindings at kde.org
CCMAIL: eric at extremeboredom.net
M +3 -0 smoke.h
--- trunk/KDE/kdebindings/smoke/smoke.h #895454:895455
@@ -327,6 +327,7 @@
while (imax >= imin) {
icur = (imin + imax) / 2;
+ if (!icur) return 0;
icmp = strcmp(types[icur].name, t);
if (icmp == 0) {
return icur;
@@ -351,6 +352,7 @@
while (imax >= imin) {
icur = (imin + imax) / 2;
+ if (!icur) return NullModuleIndex;
icmp = strcmp(classes[icur].className, c);
if (icmp == 0) {
if (classes[icur].external && !external) {
@@ -428,6 +430,7 @@
while (imax >= imin) {
icur = (imin + imax) / 2;
+ if (!icur) return NullModuleIndex;
icmp = leg(methodMaps[icur].classId, c);
if (icmp == 0) {
icmp = leg(methodMaps[icur].name, name);
More information about the Kde-bindings
mailing list