You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@camel.apache.org by "Willem Jiang (JIRA)" <ji...@apache.org> on 2010/09/02 05:50:40 UTC
[jira] Updated: (CAMEL-3100) ${file:length} should return 0 instead
of null if the file length is 0
[ https://issues.apache.org/activemq/browse/CAMEL-3100?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Willem Jiang updated CAMEL-3100:
--------------------------------
Assignee: Willem Jiang
Description:
{code}
--- camel-core/src/main/java/org/apache/camel/component/file/GenericFile.java (revision 991781)
+++ camel-core/src/main/java/org/apache/camel/component/file/GenericFile.java (working copy)
@@ -122,7 +122,8 @@
message.setHeader("CamelFileRelativePath", getRelativeFilePath());
message.setHeader(Exchange.FILE_PARENT, getParent());
- if (getFileLength() > 0) {
+ if (getFileLength() >= 0) {
message.setHeader("CamelFileLength", getFileLength());
}
if (getLastModified() > 0) {
{code}
was:
--- camel-core/src/main/java/org/apache/camel/component/file/GenericFile.java (revision 991781)
+++ camel-core/src/main/java/org/apache/camel/component/file/GenericFile.java (working copy)
@@ -122,7 +122,8 @@
message.setHeader("CamelFileRelativePath", getRelativeFilePath());
message.setHeader(Exchange.FILE_PARENT, getParent());
- if (getFileLength() > 0) {
+ if (getFileLength() >= 0) {
message.setHeader("CamelFileLength", getFileLength());
}
if (getLastModified() > 0) {
> ${file:length} should return 0 instead of null if the file length is 0
> ----------------------------------------------------------------------
>
> Key: CAMEL-3100
> URL: https://issues.apache.org/activemq/browse/CAMEL-3100
> Project: Apache Camel
> Issue Type: Bug
> Reporter: Willem Jiang
> Assignee: Willem Jiang
> Fix For: 2.5.0
>
>
> {code}
> --- camel-core/src/main/java/org/apache/camel/component/file/GenericFile.java (revision 991781)
> +++ camel-core/src/main/java/org/apache/camel/component/file/GenericFile.java (working copy)
> @@ -122,7 +122,8 @@
> message.setHeader("CamelFileRelativePath", getRelativeFilePath());
> message.setHeader(Exchange.FILE_PARENT, getParent());
>
> - if (getFileLength() > 0) {
> + if (getFileLength() >= 0) {
> message.setHeader("CamelFileLength", getFileLength());
> }
> if (getLastModified() > 0) {
> {code}
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.