# HG changeset patch # User Stefan Vogel # Date 1550852179 -3600 # Node ID 25630ec531afd051cac47efad24113ee2ef1b2ef # Parent 1853419df3c0a932a7b91ff95af21c6e63fcc1cd #BUGFIX by stefan class: ResourcePack changed: #readFromResourceStream:in: avoid DNU in short context chain diff -r 1853419df3c0 -r 25630ec531af ResourcePack.st --- a/ResourcePack.st Fri Feb 22 16:26:34 2019 +0100 +++ b/ResourcePack.st Fri Feb 22 17:16:19 2019 +0100 @@ -408,7 +408,7 @@ |fullName pack rsrcDir file| package isNil ifTrue:[ - '[ResourcePack] warning: nil package asking for resource file'. + "/ '[ResourcePack] warning: nil package asking for resource file'. defaultIfAbsentBoolean ifFalse:[^ nil]. ^ self newDefaultResourcePackForPackage:package ]. @@ -1769,19 +1769,18 @@ pushedSkipValues := OrderedCollection new. errorHandler := [:ex | - |con| + |con count| - Transcript showCR:('ResourcePack [warning]: ''' , ex description , '''') "errorPrintCR". - Transcript showCR:('ResourcePack [info]: file: ' , inStream pathName printString , ' line: ' , lineNumber printString , ': ''' , lineString , '''') "errorPrintCR". + Logger warning:('ResourcePack [warning]: ''' , ex description , ''''). + Logger info:('ResourcePack [info]: file: ' , inStream pathName printString , ' line: ' , lineNumber printString , ': ''' , lineString , '''') "errorPrintCR". con := ex suspendedContext. - Transcript showCR:('ResourcePack [info]: in: ' , con fullPrintString) "errorPrintCR". + Logger info:('ResourcePack [info]: in: ' , con fullPrintString). con := con sender. - Transcript showCR:('ResourcePack [info]: : ' , con fullPrintString) "errorPrintCR". - 30 timesRepeat:[ - con notNil ifTrue:[ - con := con sender. - Transcript showCR:('ResourcePack [info]: : ' , con fullPrintString) "errorPrintCR". - ]. + count := 1. + [con notNil and:[count <= 20]] whileTrue:[ + Logger info:('ResourcePack [info]: : ' , con fullPrintString) . + count := count + 1. + con := con sender. ]. value := nil. ok := false. @@ -1909,7 +1908,7 @@ "Modified: / 31-08-1995 / 02:33:45 / claus" "Modified: / 18-09-2006 / 20:35:37 / cg" "Modified: / 10-10-2018 / 14:14:00 / sr" - "Modified: / 22-02-2019 / 16:26:16 / Stefan Vogel" + "Modified: / 22-02-2019 / 17:13:13 / Stefan Vogel" ! !