Hi
It seems bug in DCE 6, when I try eval : "AXControlSite example3". And then image crash. =============================================================== 0:11:46, 3 oaa?aey 2006 a.: 'Invalid access to memory location. Writing 0x6C006F, IP 0x77FCC8E1 (D:\WINNT\system32\ntdll.dll)' ProcessorScheduler>>gpFault: [] in ProcessorScheduler>>vmi:list:no:with: BlockClosure>>ifCurtailed: ProcessorScheduler>>vmi:list:no:with: OLEAutLibrary(ExternalLibrary)>>invalidCall OLEAutLibrary>>variantClear: VARIANT class>>clear: StructureArray>>basicFree StructureArray(ExternalStructure)>>free StructureArray(Object)>>finalize MemoryManager>>administerLastRites MemoryManager>>finalizerMain [] in MemoryManager>>forkFinalizer ExceptionHandler(ExceptionHandlerAbstract)>>markAndTry [] in ExceptionHandler(ExceptionHandlerAbstract)>>try: BlockClosure>>ifCurtailed: BlockClosure>>ensure: ExceptionHandler(ExceptionHandlerAbstract)>>try: BlockClosure>>on:do: [] in BlockClosure>>newProcess ================================================================ Pavel. PS. I triyng on fresh image DCE6. Also I try it in DVE5 - all works fine. |
Pavel,
> It seems bug in DCE 6, when I try eval : "AXControlSite example3". > And then image crash. I've recorded this as #2084 and we'll take a look ASAP. Best regards -- Andy Bower Dolphin Support www.object-arts.com |
Andy,
> > > It seems bug in DCE 6, when I try eval : "AXControlSite example3". > > And then image crash. > > I've recorded this as #2084 and we'll take a look ASAP. Incidentally, that example no longer works even in D5 unless you have an outdated version of visual studio installed. The problem is that MS have stopped shipping a license for that grid control with their development tools, so -- even on a machine with VS.Net installed -- the grid control just whinges about not being licensed. For anyone who is interested, you have to evaluate code like the following (taken from a long-ago post from Blair) to get the licence key: "** Have to run this on a machine where VS6 is installed **" pFactory := IClassFactory2 newPointer. OLELibrary default coGetClassObject: (CLSID fromString: 'MSFlexGridLib.MSFlexGrid') dwClsContext: IClassFactory ctxServer pServerInfo: nil riid: pFactory iid ppv: pFactory. licenseKey := pFactory requestLicenseKey Without the key, on my machine, the example just fails normally. With it, D6 does indeed crash... -- chris |
In reply to this post by Andy Bower-3
"Andy Bower" <[hidden email]> wrote in message
news:[hidden email]... > Pavel, > >> It seems bug in DCE 6, when I try eval : "AXControlSite example3". >> And then image crash. > > I've recorded this as #2084 and we'll take a look ASAP. > It turns out that this is due to an error in DISPPARAMS>>names:named:args:, which causes a double-free of VARIANTs containing BSTRs. This corrupts the process heap, which sooner of later (there are a lot of double-frees) causes the process to fall over. This bug was also present in D5, but for some reason it was more tolerant of the problem and did not crash quite so immediately. In the standard image the only use of this method is from IDispatch>>setPropertyId:withArguments:value:, which in turn is only used from AXControlSite class>>example3. If you are using late-bound IDispatch to set properties, etc, then I would recommend installing the patch below, otherwise wait for the next patch level. Thanks Blair ----------- !DISPPARAMS methodsFor! names: names named: namedArgs args: unnamedArgs "Set the receiver's arguments to be the <sequencedReadableCollection> of named arguments, namedArgs, the names (ids) of which are specified in the corresponding positions of the <sequencedReadableCollection>, dispids, and the <sequencedReadableCollection> of unnamed <Object> arguments, args." | argc cNamed cUnnamed | cNamed := namedArgs size. dispids := SDWORDArray new: cNamed. cUnnamed := unnamedArgs size. argc := cNamed + cUnnamed. args := Array new: argc. vargs := StructureArray length: argc elementClass: VARIANT. "#2084: Suppress structure array finalization which would double-free the variants" vargs owner: args. "Named args can appear in normal order" 1 to: cNamed do: [:i | | v | dispids at: i put: (names at: i). v := (namedArgs at: i) asVariant. vargs at: i put: (args at: i put: v)]. "Unnamed args must appear in reverse order" 1 to: cUnnamed do: [:i | | v j | v := (unnamedArgs at: i) asVariant. j := argc - i + 1. vargs at: j put: (args at: j put: v)]. self rgdispidNamedArgs: dispids. self cNamedArgs: cNamed. self rgvarg: vargs. self cArgs: argc! ! !DISPPARAMS categoriesFor: #names:named:args:!accessing!public! ! |
Free forum by Nabble | Edit this page |