From 759c7bd58b86b18408d786f89e2553e781840f9a Mon Sep 17 00:00:00 2001 From: Dan Stillman Date: Wed, 7 Mar 2012 11:34:31 -0500 Subject: [PATCH] Fix metadata retrieval for files with extended characters in filenames --- chrome/content/zotero/recognizePDF.js | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/chrome/content/zotero/recognizePDF.js b/chrome/content/zotero/recognizePDF.js index 11754ec3bc..72b6cb3ca7 100644 --- a/chrome/content/zotero/recognizePDF.js +++ b/chrome/content/zotero/recognizePDF.js @@ -269,7 +269,18 @@ Zotero_RecognizePDF.Recognizer.prototype.recognize = function(file, libraryID, c var args = ['-enc', 'UTF-8', '-nopgbrk', '-layout', '-l', MAX_PAGES]; args.push(file.path, cacheFile.path); - proc.run(true, args, args.length); + try { + if (!Zotero.isFx36) { + proc.runw(true, args, args.length); + } + else { + proc.run(true, args, args.length); + } + } + catch (e) { + Zotero.debug("Error running pdfinfo", 1); + Zotero.debug(e, 1); + } if(!cacheFile.exists()) { this._callback(false, "recognizePDF.couldNotRead");