Skip to content

Conversation

@mtbc
Copy link
Member

@mtbc mtbc commented Feb 13, 2013

Note that the class has associated unit tests which may assist in testing this PR.

@jburel
Copy link
Member

jburel commented Feb 13, 2013

@MtC: see http://trac.openmicroscopy.org.uk/ome/ticket/383, we could maybe start with that test ;-) and remove the System.err/out

@mtbc
Copy link
Member Author

mtbc commented Feb 14, 2013

True, but in this case we definitely want some of the standard file descriptor output because the class is also offering a command-line interface that prints stuff out for the user; rather than removing them, we'd probably have to somehow thread logic through to check how the methods are being called.

@joshmoore
Copy link
Member

Agreed: Since this is a command-line tool, it definitely needs System.out|err.

@jburel
Copy link
Member

jburel commented Feb 14, 2013

ok.

@joshmoore
Copy link
Member

Trivial invocation worked cleanly.

omero@gretzky:~/OMERO-CURRENT/lib/server$ java -cp blitz.jar:server.jar omero.util.TempFileManager clean
Deleted: /home/omero/omero/tmp/omero_omero/13576
Deleted: /home/omero/omero/tmp/omero_omero/27933
Deleted: /home/omero/omero/tmp/omero_omero/2623
Deleted: /home/omero/omero/tmp/omero_omero/27934
Deleted: /home/omero/omero/tmp/omero_omero/7139
Deleted: /home/omero/omero/tmp/omero_omero/28778
Deleted: /home/omero/omero/tmp/omero_omero/2277
...

joshmoore added a commit that referenced this pull request Feb 15, 2013
Close resource leak in temporary file manager.
@joshmoore joshmoore merged commit 4619dcf into ome:dev_4_4 Feb 15, 2013
@mtbc mtbc deleted the tempfilemgr-leak branch February 15, 2013 12:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants