On Mon, Mar 02 2015, Trevor Jim <[email protected]> wrote:

> ---
>  bindings/go/src/notmuch/notmuch.go | 8 +++++++-
>  1 file changed, 7 insertions(+), 1 deletion(-)
>
> diff --git a/bindings/go/src/notmuch/notmuch.go 
> b/bindings/go/src/notmuch/notmuch.go
> index b9230ad..f5fd54c 100644
> --- a/bindings/go/src/notmuch/notmuch.go
> +++ b/bindings/go/src/notmuch/notmuch.go
> @@ -801,7 +801,13 @@ func (self *Message) SetFlag(flag Flag, value bool) {
>       C.notmuch_message_set_flag(self.message, 
> C.notmuch_message_flag_t(flag), v)
>  }
>  
> -// TODO: wrap notmuch_message_get_date
> +func  (self *Message) GetDate() int64 {
> +     if self.message == nil {
> +             return -1

-1 is 1969-dec-31 23:59:59 UTC

Should we care -- and e.g. return status in separate return value ?

Tomi

> +     }
> +     timestamp := C.notmuch_message_get_date(self.message)
> +     return int64(timestamp)
> +}
>  
>  /* Get the value of the specified header from 'message'.
>   *
> -- 
> 2.2.2
_______________________________________________
notmuch mailing list
[email protected]
http://notmuchmail.org/mailman/listinfo/notmuch

Reply via email to