Revert "More resources closes" for file still in use.
authorPatrick Tasse <patrick.tasse@gmail.com>
Tue, 22 May 2012 21:24:45 +0000 (17:24 -0400)
committerPatrick Tasse <patrick.tasse@gmail.com>
Tue, 22 May 2012 21:24:45 +0000 (17:24 -0400)
org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/internal/tmf/ui/parsers/custom/CustomTxtTrace.java

index 1ed80c0a471c384925517a683dd87304d0d75fbd..4fbbe2ee6e16d4a6d2f4677e8826e4899d1b7bd0 100644 (file)
@@ -64,9 +64,8 @@ public class CustomTxtTrace extends TmfTrace<CustomTxtEvent> implements ITmfEven
         final CustomTxtTraceContext context = new CustomTxtTraceContext(NULL_LOCATION, ITmfContext.UNKNOWN_RANK);\r
         if (NULL_LOCATION.equals(location) || !new File(getPath()).isFile())\r
             return context;\r
-        BufferedRandomAccessFile raFile = null;\r
         try {\r
-            raFile = new BufferedRandomAccessFile(getPath(), "r"); //$NON-NLS-1$\r
+            BufferedRandomAccessFile raFile = new BufferedRandomAccessFile(getPath(), "r"); //$NON-NLS-1$\r
             if (location != null && location.getLocation() instanceof Long) {\r
                 raFile.seek((Long)location.getLocation());\r
             }\r
@@ -94,13 +93,6 @@ public class CustomTxtTrace extends TmfTrace<CustomTxtEvent> implements ITmfEven
         } catch (final IOException e) {\r
             TmfUiPlugin.getDefault().logError("Error seeking event. File: " + getPath(), e); //$NON-NLS-1$\r
             return context;\r
-        } finally {\r
-            if (raFile != null) {\r
-                try {\r
-                    raFile.close();\r
-                } catch (final IOException e) {\r
-                }\r
-            }\r
         }\r
 \r
     }\r
This page took 0.035868 seconds and 5 git commands to generate.