MAJ terminée. Nous sommes passés en version 14.6.2 . Pour consulter les "releases notes" associées c'est ici :

https://about.gitlab.com/releases/2022/01/11/security-release-gitlab-14-6-2-released/
https://about.gitlab.com/releases/2022/01/04/gitlab-14-6-1-released/

Commit 7c81783c authored by Fabien Triolet's avatar Fabien Triolet
Browse files

Readers can read stdin now

parent 2ca3b020
/*
* $Id: TReader.java,v 1.4 2003-01-07 08:13:59 triolet Exp $
* $Id: TReader.java,v 1.5 2003-02-06 08:36:42 triolet Exp $
*
* Transmorpher
*
......@@ -171,11 +171,11 @@ public abstract class TReader extends TProcessBasic {
try {
//System.out.println("[test evalParameter] "+getParameters().evalParameter("file"));
//System.out.println(getParameter("file"));
//super.bindParameters(getParameters());
iFilename = (String)getParameters().evalParameter("file");
//getParameters().setParameters(param);
super.bindParameters(getParameters());
iFilename = (String)getParameter("file");
getParameters().setParameters(param);
if (iFilename != null) {
if ((iFilename != null)&&(!(iFilename.equals("_stdin_")))) {
if (iFilename.startsWith("http://")) {
URL url = new URL(iFilename);
URLConnection urlConnect = url.openConnection();
......@@ -187,17 +187,18 @@ public abstract class TReader extends TProcessBasic {
inSource = new InputSource(new FileInputStream(file));
inSource.setSystemId(file.toURL().toString());
}
if (isThread) {
procThread.start();
if (raisedException != null) {
throw new TMRuntimeException(raisedException, "Thread reading error");
}
} else {
read();
}
} else {
inSource = new InputSource(System.in);
}
if (isThread) {
procThread.start();
if (raisedException != null) {
throw new TMRuntimeException(raisedException, "Thread reading error");
}
} else {
read();
}
} catch (IOException e) {
// JE: There is a problem here either we report the error,
......@@ -207,7 +208,11 @@ public abstract class TReader extends TProcessBasic {
// Send the empty document on error!?
iReader.getContentHandler().startDocument();
iReader.getContentHandler().endDocument();
} catch (TMException e) {}
}
catch (TMException e) {}
catch (SAXException e){
e.printStackTrace();
}
}
/**
......
/*
* $Id: ReadFile.java,v 1.3 2002-11-14 15:46:45 triolet Exp $
* $Id: ReadFile.java,v 1.4 2003-02-06 08:36:42 triolet Exp $
*
* Transmorpher
*
......@@ -86,6 +86,7 @@ public final class ReadFile extends TReader {
try {
iReader.parse(getInputSource());
} catch (Exception e) {
e.printStackTrace();
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment