]> git.ipfire.org Git - ipfire-3.x.git/blobdiff - perl-Tk/patches/perl-Tk-seg.patch
perl-Tk: New package.
[ipfire-3.x.git] / perl-Tk / patches / perl-Tk-seg.patch
diff --git a/perl-Tk/patches/perl-Tk-seg.patch b/perl-Tk/patches/perl-Tk-seg.patch
new file mode 100644 (file)
index 0000000..26201fa
--- /dev/null
@@ -0,0 +1,33 @@
+diff -up Tk-804.028/pTk/mTk/generic/tkConfig.c.seg Tk-804.028/pTk/mTk/generic/tkConfig.c
+--- Tk-804.028/pTk/mTk/generic/tkConfig.c.seg  2008-03-11 23:29:39.000000000 -0400
++++ Tk-804.028/pTk/mTk/generic/tkConfig.c      2008-03-11 23:28:09.000000000 -0400
+@@ -1210,11 +1210,11 @@ GetOptionFromObj(interp, objPtr, tablePt
+      * First, check to see if the object already has the answer cached.
+      */
+-    if (objPtr->typePtr == &tkOptionObjType) {
++/*    if (objPtr->typePtr == &tkOptionObjType) {
+         if (objPtr->internalRep.twoPtrValue.ptr1 == (VOID *) tablePtr) {
+             return (Option *) objPtr->internalRep.twoPtrValue.ptr2;
+         }
+-    }
++    }*/
+     /*
+      * The answer isn't cached.
+@@ -2277,9 +2277,15 @@ Tk_GetOptionValue(interp, recordPtr, opt
+     if (optionPtr == NULL) {
+       return NULL;
+     }
++
++    if (optionPtr->specPtr == NULL) {
++      return NULL;
++    }
++
+     if (optionPtr->specPtr->type == TK_OPTION_SYNONYM) {
+       optionPtr = optionPtr->extra.synonymPtr;
+     }
++
+     if (optionPtr->specPtr->objOffset >= 0) {
+       resultPtr = *((Tcl_Obj **) (recordPtr + optionPtr->specPtr->objOffset));
+       if (resultPtr == NULL) {