From 573b065d338f91d27924ec2f217f8f4a0c79a1d8 Mon Sep 17 00:00:00 2001 From: Anton Leherbauer Date: Fri, 31 Aug 2007 06:34:56 +0000 Subject: [PATCH] Revert handling of InterruptedException --- .../utils/org/eclipse/cdt/utils/Platform.java | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/core/org.eclipse.cdt.core/utils/org/eclipse/cdt/utils/Platform.java b/core/org.eclipse.cdt.core/utils/org/eclipse/cdt/utils/Platform.java index a99aab2b13f..f2624ad1a26 100644 --- a/core/org.eclipse.cdt.core/utils/org/eclipse/cdt/utils/Platform.java +++ b/core/org.eclipse.cdt.core/utils/org/eclipse/cdt/utils/Platform.java @@ -16,6 +16,8 @@ package org.eclipse.cdt.utils; import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; + +import org.eclipse.cdt.core.CCorePlugin; import org.osgi.framework.Bundle; public final class Platform { @@ -64,9 +66,10 @@ public final class Platform { bufferedReader.close(); unameProcess.waitFor(); // otherwise the process becomes a zombie } catch (IOException e) { + CCorePlugin.log(e); } catch (InterruptedException exc) { - // clear interrupted state - Thread.interrupted(); + // restore interrupted flag + Thread.currentThread().interrupt(); } } else if (arch.equals(org.eclipse.core.runtime.Platform.ARCH_X86)) { // Determine if the platform is actually a x86_64 machine @@ -90,9 +93,10 @@ public final class Platform { bufferedReader.close(); unameProcess.waitFor(); // otherwise the process becomes a zombie } catch (IOException e) { + CCorePlugin.log(e); } catch (InterruptedException exc) { - // clear interrupted state - Thread.interrupted(); + // restore interrupted flag + Thread.currentThread().interrupt(); } } cachedArch= arch;