Hi Andrew:

A build of the test_noninteractive target generates the following java warnings

cd /home/software/plplot/HEAD/build_dir/examples/java && /usr/bin/javac 
-classpath /home/software/plplot/HEAD/build_dir/bindings/java -d 
/home/software/plplot/HEAD/build_dir/examples/java -encoding UTF-8 
/home/software/plplot/HEAD/plplot.git/examples/java/x20.java
/home/software/plplot/HEAD/plplot.git/examples/java/x20.java:328: warning: 
Resource leak: 'in' is never closed
        in  = new BufferedReader( new FileReader( fname ) );
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
/home/software/plplot/HEAD/plplot.git/examples/java/x20.java:329: warning: 
Resource leak: 'in2' is never closed
        in2 = new DataInputStream( new DataInputStream( new 
BufferedInputStream( new FileInputStream( fname ) ) ) );
        
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2 problems (2 warnings)

Those are the only java warnings I get so we are in pretty good shape
with regard to the Java examples, but it would be nice to get rid of
these warnings completely.

For my Debian stable platform, javac refers to a gcj wrapper, i.e.,

software@raven> ls -l /etc/alternatives/javac
lrwxrwxrwx 1 root root 24 Oct  4 12:56 /etc/alternatives/javac -> 
/usr/bin/gcj-wrapper-4.9*

You can also generate these specific java example 20 warnings with the 
following much simpler
test:

software@raven> make VERBOSE=1 x20j >| x20j.out 2>&1

I have attached a compressed version of x20j.out to give you full
context.

Would you be willing to take a look at this?

Alan
__________________________
Alan W. Irwin

Astronomical research affiliation with Department of Physics and Astronomy,
University of Victoria (astrowww.phys.uvic.ca).

Programming affiliations with the FreeEOS equation-of-state
implementation for stellar interiors (freeeos.sf.net); the Time
Ephemerides project (timeephem.sf.net); PLplot scientific plotting
software package (plplot.sf.net); the libLASi project
(unifont.org/lasi); the Loads of Linux Links project (loll.sf.net);
and the Linux Brochure Project (lbproject.sf.net).
__________________________

Linux-powered Science
__________________________

Attachment: x20j.out.gz
Description: complete build output for Java example 20 (x20j)

------------------------------------------------------------------------------
Presto, an open source distributed SQL query engine for big data, initially
developed by Facebook, enables you to easily query your data on Hadoop in a 
more interactive manner. Teradata is also now providing full enterprise
support for Presto. Download a free open source copy now.
http://pubads.g.doubleclick.net/gampad/clk?id=250295911&iu=/4140
_______________________________________________
Plplot-devel mailing list
Plplot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/plplot-devel

Reply via email to