EDPro Shell integration interferes with java.awt.Desktop

General questions about using ExamDiff Pro, ideas for new features, bug reports, and usage tips.
Post Reply
MudGuard
Expert Member
Posts: 69
Joined: Mon Jun 07, 2004 12:42 am

EDPro Shell integration interferes with java.awt.Desktop

Post by MudGuard »

I thought I posted this earlier on, but now when looking whether there is an answer I can't find the post ...

Somehow EDPro Shell integration interferes with Java VM (esp. java.awt.Desktop).

If I have EDPro Shell integration active, a java program using
java.awt.Desktop.getDesktop().open(new java.io.File("c:\\temp\\test.pdf"));
leads to a crash of the VM.
If I switch off EDPro Shell integration, the program runs without problems, opening the PDF.

This mini program

Code: Select all

package de.einsurance.tests;
import java.awt.Desktop;
import java.io.File;
public class Desktoptest {
	public static void main(String[] args) 	{
		System.out.println("BEFORE");
		try {
			Desktop.getDesktop().open(new File("c:\\temp\\test.pdf"));
		} catch (Throwable e) {
			e.printStackTrace();
		}
		System.out.println("AFTER");
	}
}
shows the effect. Without EDPro Shell integration, it writes
BEFORE
AFTER
and inbetween opens the pdf reader.

With EDPro Shell integration, I get

BEFORE
#
# A fatal error has been detected by the Java Runtime Environment:
#
# EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x77bd15a5, pid=6536, tid=6876
#
# JRE version: 6.0_18-b07
# Java VM: Java HotSpot(TM) Client VM (16.0-b13 mixed mode windows-x86 )
# Problematic frame:
# C [VERSION.dll+0x15a5]
#
# An error report file with more information is saved as:
# C:\Projects\hs_err_pid6536.log
#
# If you would like to submit a bug report, please visit:
# http://java.sun.com/webapps/bugreport/crash.jsp
# The crash happened outside the Java Virtual Machine in native code.
# See problematic frame for where to report the bug.
#

in the hs_err_pid6536.log (I don't want to publish it completely, but could send it to you) it shows

Code: Select all

Stack: [0x495c0000,0x49610000],  sp=0x4960eb2c,  free space=13a4960e660k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
C  [VERSION.dll+0x15a5]
C  [VERSION.dll+0x1821]
C  [EDPShell.dll+0x5593]
C  [EDPShell.dll+0x665f]
C  [EDPShell.dll+0xa02c]
(the EDPShell.dll is what made me test with/without shell integration)


This is very annoying, as I need both the shell integration as well as my program being able to display pdfs and other files ...

(I am registered user, I run EDPro 5.0.0.5 - updating to 5.0.0.19 didn't help, the problem persists. Java JKD is 1.6.0.18)

Andreas
User avatar
psguru
Site Admin
Posts: 2232
Joined: Sat May 15, 2004 4:23 pm
Location: California
Contact:

Re: EDPro Shell integration interferes with java.awt.Desktop

Post by psguru »

Thanks for reporting this; we'll take a look at the problem and I'll post results here.
psguru
PrestoSoft
MudGuard
Expert Member
Posts: 69
Joined: Mon Jun 07, 2004 12:42 am

Re: EDPro Shell integration interferes with java.awt.Desktop

Post by MudGuard »

If I can provide more info, please ask.

Btw, I have Windows XP SP3, all updates.
I have no other Windows version to test on ...

The problem also occurs with txt or doc or xml or png - it is not a problem pdf-reader vs. edpro ...

I also have Winzip installed, which also adds menu items to the explorer context menu. But Winzip does not interfere with java.awt.Desktop
User avatar
psguru
Site Admin
Posts: 2232
Joined: Sat May 15, 2004 4:23 pm
Location: California
Contact:

Re: EDPro Shell integration interferes with java.awt.Desktop

Post by psguru »

I couldn't reproduce this problem. I tried on both XP and Windows Server 2008 (x64). On XP, my version is Windows XP 32-bit Professional Edition 5.1 Service Pack 3 (Build 2600). I downloaded the latest JDK (JDK 6 Update 18), and your code ran without problems.

Perhaps you could break your Java code and check in the Process Explorer what EDPShell.dll is actually loaded in the process. It's possible that an older DLL from some other location is loaded. Also, it would help you could send me a minidump of the crash.
psguru
PrestoSoft
MudGuard
Expert Member
Posts: 69
Joined: Mon Jun 07, 2004 12:42 am

Re: EDPro Shell integration interferes with java.awt.Desktop

Post by MudGuard »

I sent you the crash report by private message (last night).

There is exactly one EDPShell.dll on the system, in folder C:\Programme\ExamDiff Pro.
It has a size of 170.232 Bytes, a creation date of 2008-03-28T14:11:13, a modify date of 2010-03-15T20:26:28 (the time I updated to 5.0.0.19).

I can reproduce the problem on a second system (setup is very similar).
User avatar
psguru
Site Admin
Posts: 2232
Joined: Sat May 15, 2004 4:23 pm
Location: California
Contact:

Re: EDPro Shell integration interferes with java.awt.Desktop

Post by psguru »

I tried to reproduce this on a different XP box but no luck. How about this: will you be able to use a special build of EDPShell.dll with debug traces (alongside with DebugView) and send me the traces after the crash?
psguru
PrestoSoft
MudGuard
Expert Member
Posts: 69
Joined: Mon Jun 07, 2004 12:42 am

Re: EDPro Shell integration interferes with java.awt.Desktop

Post by MudGuard »

should be no problem to replace the dll (I am local admin on that machine).

But you need to tell me how to retrieve the debug traces stuff.
User avatar
psguru
Site Admin
Posts: 2232
Joined: Sat May 15, 2004 4:23 pm
Location: California
Contact:

Re: EDPro Shell integration interferes with java.awt.Desktop

Post by psguru »

I just sent you the instructions via a PM. If you can't replace the DLL, kill the Windows Explorer process that is holding the DLL in memory. You can find this out using Process Explorer or the tasklist command.
psguru
PrestoSoft
MudGuard
Expert Member
Posts: 69
Joined: Mon Jun 07, 2004 12:42 am

Re: EDPro Shell integration interferes with java.awt.Desktop

Post by MudGuard »

case closed, problem was probably an incorrectly registered (in windows system) dll.

Thanks again for the great support - although it is Saturday late night (at least here in Munich) - correction, early Sunday morning, Gregory helped me (via pm, as some non-public information was involved) finding the problem all the same.

A big THANKS! from Munich, Germany!

Andreas a/k/a MudGuard
Post Reply