diff options
author | Thomas Watson | 2006-07-17 12:45:29 +0000 |
---|---|---|
committer | Thomas Watson | 2006-07-17 12:45:29 +0000 |
commit | 3f76e8aa09b135bf3f2f357f77390cae344b9e45 (patch) | |
tree | 984610fc28864c8a8994d4432a574643c4413710 | |
parent | 11f8aff18ec949545666a57abc2dffcde488cd32 (diff) | |
download | rt.equinox.framework-3f76e8aa09b135bf3f2f357f77390cae344b9e45.tar.gz rt.equinox.framework-3f76e8aa09b135bf3f2f357f77390cae344b9e45.tar.xz rt.equinox.framework-3f76e8aa09b135bf3f2f357f77390cae344b9e45.zip |
Bug 141288 nullpointer in StateWriter class
-rw-r--r-- | bundles/org.eclipse.osgi/resolver/src/org/eclipse/osgi/internal/resolver/StateWriter.java | 22 |
1 files changed, 12 insertions, 10 deletions
diff --git a/bundles/org.eclipse.osgi/resolver/src/org/eclipse/osgi/internal/resolver/StateWriter.java b/bundles/org.eclipse.osgi/resolver/src/org/eclipse/osgi/internal/resolver/StateWriter.java index 8cd2bad9c..eec6e7dc6 100644 --- a/bundles/org.eclipse.osgi/resolver/src/org/eclipse/osgi/internal/resolver/StateWriter.java +++ b/bundles/org.eclipse.osgi/resolver/src/org/eclipse/osgi/internal/resolver/StateWriter.java @@ -123,29 +123,31 @@ class StateWriter { outState.writeBoolean(state.isResolved()); state.setDynamicCacheChanged(false); } finally { - if (outLazy != null) + if (outLazy != null) { try { outLazy.flush(); fosLazy.getFD().sync(); } catch (IOException e) { // do nothing, we tried } - try { - outLazy.close(); - } catch (IOException e) { - // do nothing + try { + outLazy.close(); + } catch (IOException e) { + // do nothing + } } - if (outState != null) + if (outState != null) { try { outState.flush(); fosState.getFD().sync(); } catch (IOException e) { // do nothing, we tried } - try { - outState.close(); - } catch (IOException e) { - // do nothing + try { + outState.close(); + } catch (IOException e) { + // do nothing + } } } } |