[Saga-devel] saga SVN commit 3288: /trunk/adaptors/default/file/
Hartmut Kaiser
hkaiser at cct.lsu.edu
Thu Jan 15 07:36:48 CST 2009
Andre,
> User: amerzky
> Date: 2009/01/15 05:37 AM
>
> Modified:
> /trunk/adaptors/default/file/
> common_helpers.hpp, default_namespace_dir_impl.hpp
>
> Log:
> - fix escaping - hope that breaks nothing else
> - boost seems to be unable to handle filenames with spaces? added
Sure it handles those correctly. There must be something else. What's your
problem?
> try/catch for sync_list
> Hartmut, do these make sense?
See below.
> A
>
> File Changes:
>
> Directory: /trunk/adaptors/default/file/
> ========================================
>
> File [modified]: common_helpers.hpp
> Delta lines: +1 -1
> ===================================================================
> --- trunk/adaptors/default/file/common_helpers.hpp 2009-01-15
> 10:39:34 UTC (rev 3287)
> +++ trunk/adaptors/default/file/common_helpers.hpp 2009-01-15
> 11:37:10 UTC (rev 3288)
> @@ -70,7 +70,7 @@
> inline std::string
> get_filepath(saga::url const& loc)
> {
> - return loc.get_path();
> + return saga::url::unescape (loc.get_path());
Yeah, this seems to be correct, as everything returned by the url class is
escaped. Using this with OS calls leads to problems, so unescaping is
needed.
> fs::directory_iterator dir_end = fs::directory_iterator();
> for (fs::directory_iterator dir_it(path); dir_it != dir_end;
> ++dir_it)
> {
> - //retval.push_back(host + saga::detail::leaf((*dir_it))); see
> --> Spec. p. 141
> - retval.push_back(saga::detail::leaf(*dir_it));
> + try {
> + //retval.push_back(host + saga::detail::leaf((*dir_it)));
> see --> Spec. p. 141
> + retval.push_back(saga::detail::leaf(*dir_it));
Does this mean list has to return the relative paths? Hmm, I remember fixing
something like this already, but perhaps in a different adaptor...
> + }
> + catch ( ... )
> + {
> + // ignore this one
> + SAGA_LOG_ERROR("Boost failed to handle some filename");
> + SAGA_LOG_ALWAYS("Boost failed to handle some filename");
> + }
Why don't you rethrow a saga::exception? What causes the system_exception?
More information about the saga-devel
mailing list