libextractor-java

GNU libextractor
Log | Files | Refs | README | LICENSE

commit d565b35f875f3d2db02da2615cbc4032119f2081
parent b60c9a91f44ca8fd0a5463250076345c06aa36e9
Author: Christian Grothoff <christian@grothoff.org>
Date:   Tue,  4 Jul 2006 18:42:24 +0000

libextractor JNI
From: 
Andrew Marrington <a.marrington@qut.edu.au>
  To: 
  christian@grothoff.org
    Date: 
    Today 02:51:57 am
       
         Spam Status: Spamassassin 0% probability of being spam.

	 Full report:
	 No, score=-2.0 required=5.0 tests=BAYES_00, MSGID_FROM_MTA_HEADER autolearn=ham version=3.1.3  Bogofilter 0% probability of being spam.

	 Full report:
	 Ham, tests=bogofilter, spamicity=0.000000, version=1.0.2  
	 Christian,

	 I am working with libextractor in a piece of Java software I've  
	 written as part of my research, and I came across a little bug in  
	 Extractor.java. It's just a tiny little thing, but it was the  
	 difference between being able to get your Xtract demo working and  
	 being able to get my own code working, which some other Java  
	 programmers might come across, so I thought I'd email you the fix  
	 (apologies if I could've just checked in a new version myself):

	 Starting at line 188 of Extractor.java:

	 public Vector extract(File f) {
	 return extract(f.getName());
	 }

	 should be:

	 public Vector extract(File f) {
	 return extract(f.getAbsolutePath());
	 }

	 getName just returns the last element of the complete filename and  
	 thus will only work for software running from the same directory.

	 libextractor is a great piece of software and will be extremely  
	 useful to my own work, thanks very much for the work you've put into  
	 this great tool!

	 Regards,

	 -----------------------------


Diffstat:
Morg/gnunet/libextractor/Extractor.java | 9++++-----
1 file changed, 4 insertions(+), 5 deletions(-)

diff --git a/org/gnunet/libextractor/Extractor.java b/org/gnunet/libextractor/Extractor.java @@ -14,8 +14,8 @@ You should have received a copy of the GNU General Public License along with libextractor; see the file COPYING. If not, write to the - Free Software Foundation, Inc., 59 Temple Place - Suite 330, - Boston, MA 02111-1307, USA. + Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, + Boston, MA 02110-1301, USA. */ package org.gnunet.libextractor; @@ -186,7 +186,7 @@ public final class Extractor { * @return a Vector of Extractor.Keywords */ public Vector extract(File f) { - return extract(f.getName()); + return extract(f.getAbsolutePath()); } /** @@ -286,4 +286,4 @@ public final class Extractor { } // end of Extractor.Keyword -} // end of Extractor -\ No newline at end of file +} // end of Extractor