[Saga-devel] saga SVN commit 3317: /trunk/adaptors/default/file/

Hartmut Kaiser hkaiser at cct.lsu.edu
Sat Jan 17 06:33:11 CST 2009


Andre,

> User: amerzky
> Date: 2009/01/17 06:09 AM
> 
> Modified:
>  /trunk/adaptors/default/file/
>   default_dir.cpp, default_file.cpp

Now the default file adaptor doesn't compile on Windows anymore! Part of the
util functions (as outlined before) isn't portable.
It's probably no problem if other adaptors don't compile there, but the
default adaptor set _has_ to be functional.

Regards Hartmut

> 
> Log:
>  use new localhost check
> 
> File Changes:
> 
> Directory: /trunk/adaptors/default/file/
> ========================================
> 
> File [modified]: default_dir.cpp
> Delta lines: +1 -1
> ===================================================================
> --- trunk/adaptors/default/file/default_dir.cpp	2009-01-17 12:05:20
UTC
> (rev 3316)
> +++ trunk/adaptors/default/file/default_dir.cpp	2009-01-17 12:09:26
UTC
> (rev 3317)
> @@ -46,7 +46,7 @@
>      fs::path path (saga::url::unescape(dir_url.get_path()),
> fs::native);
> 
>      std::string host(dir_url.get_host());
> -    if (!host.empty() && host != "localhost" && !boost::iequals(host,
> ::detail::get_hostname()))
> +    if ( ! saga::adaptors::utils::url_is_local (dir_url) )
>      {
>          SAGA_OSSTREAM strm;
>          strm << "dir_cpi_impl::init: cannot handle file: " <<
> dir_url.get_url();
> 
> File [modified]: default_file.cpp
> Delta lines: +2 -2
> ===================================================================
> --- trunk/adaptors/default/file/default_file.cpp	2009-01-17
> 12:05:20 UTC (rev 3316)
> +++ trunk/adaptors/default/file/default_file.cpp	2009-01-17
> 12:09:26 UTC (rev 3317)
> @@ -20,6 +20,7 @@
>  #include <saga/saga/exception.hpp>
>  #include <saga/saga/url.hpp>
>  #include <saga/saga/adaptors/task.hpp>
> +#include <saga/saga/adaptors/utils.hpp>
> 
>  #include <saga/impl/config.hpp>
> 
> @@ -49,8 +50,7 @@
>    saga::url file_url(data->location_);
>    std::string url = saga::url::unescape(file_url.get_path());
> 
> -  std::string host(file_url.get_host());
> -  if (!host.empty() && host != "localhost" && !boost::iequals(host,
> ::detail::get_hostname()))
> +  if ( ! saga::adaptors::utils::url_is_local (file_url) )
>    {
>      SAGA_OSSTREAM strm;
>      strm << "Cannot handle remote file: " << data->location_ ;
> 
> _______________________________________________
> saga-devel mailing list
> saga-devel at cct.lsu.edu
> https://mail.cct.lsu.edu/mailman/listinfo/saga-devel



More information about the saga-devel mailing list