anchor.diff:  
   
   read_link_info_int(Port, Link, TimeType) ->
  -    case drv_command(Port, [?FILE_LSTAT, pathname(Link)]) of
  -	{ok, FI} -> {ok, FI#file_info{
  -		    ctime = from_seconds(FI#file_info.ctime, TimeType),
  -		    mtime = from_seconds(FI#file_info.mtime, TimeType),
  -		    atime = from_seconds(FI#file_info.atime, TimeType)
  -		}};
  -	Error    -> Error
  +    try
  +	case drv_command(Port, [?FILE_LSTAT, pathname(Link)]) of
  +	    {ok, FI} -> {ok, FI#file_info{
  +			ctime = from_seconds(FI#file_info.ctime, TimeType),
  +			mtime = from_seconds(FI#file_info.mtime, TimeType),
  +			atime = from_seconds(FI#file_info.atime, TimeType)
  +		    }};
  +	    Error    -> Error
  +	end
  +    catch
  +	error:_ -> {error, badarg}
       end.
   
   %% list_dir/{1,2}
  
positive.code:     read_file_info_int(Port, File, plgv(time, Opts, local)).
  
  read_file_info_int(Port, File, TimeType) ->
      case drv_command(Port, [?FILE_FSTAT, pathname(File)]) of
  	{ok, FI} -> {ok, FI#file_info{
  		    ctime = from_seconds(FI#file_info.ctime, TimeType),
  		    mtime = from_seconds(FI#file_info.mtime, TimeType),
  		    atime = from_seconds(FI#file_info.atime, TimeType)
  		}};
  	Error    -> Error
      end.
  
  
  
negative.code:     %  - use atime as mtime if mtime is undefined
      %  - use mtime as ctime if ctime is undefined
  
      try
  	Atime = file_info_validate_atime(Atime0, TimeType),
  	Mtime = file_info_validate_mtime(Mtime0, Atime),
  	Ctime = file_info_validate_ctime(Ctime0, Mtime),
  
  	drv_command(Port, [?FILE_WRITE_INFO, 
  		int_to_int32bytes(Mode), 
  		int_to_int32bytes(Uid), 
  		int_to_int32bytes(Gid),
  		int_to_int64bytes(to_seconds(Atime, TimeType)), 
  		int_to_int64bytes(to_seconds(Mtime, TimeType)), 
  		int_to_int64bytes(to_seconds(Ctime, TimeType)),
  		pathname(File)])
      catch
  	error:_ -> {error, badarg}
      end.
  
  
  file_info_validate_atime(Atime, _) when Atime =/= undefined -> Atime;
  file_info_validate_atime(undefined, local) -> erlang:localtime();
  file_info_validate_atime(undefined, utc)   -> erlang:universaltime();
  file_info_validate_atime(undefined, epoch) -> erlang:universaltime_to_seconds((erlang:universaltime())).
  
  file_info_validate_mtime(undefined, Atime) -> Atime;
  file_info_validate_mtime(Mtime, _)         -> Mtime.
  