[PATCH] osutil: fix the declaration to work on different sizes of off_t

Augie Fackler raf at durin42.com
Thu Sep 8 14:29:34 EDT 2016


On Thu, Sep 08, 2016 at 10:38:08AM +0200, Maciej Fijalkowski wrote:
> # HG changeset patch
> # User fijal
> # Date 1473323878 -7200
> #      Thu Sep 08 10:37:58 2016 +0200
> # Node ID 8db87163c95d79da03644e3850551f3bfa802262
> # Parent  e20945831e4f9362d2e113bafe527e2a0554f4b4
> osutil: fix the declaration to work on different sizes of off_t

Queued, thanks

>
> diff --git a/setup_osutil_cffi.py b/setup_osutil_cffi.py
> --- a/setup_osutil_cffi.py
> +++ b/setup_osutil_cffi.py
> @@ -45,6 +45,8 @@
>      ...;
>  } attrreference_t;
>
> +typedef int ... off_t;
> +
>  typedef struct val_attrs {
>      uint32_t          length;
>      attribute_set_t   returned;
> @@ -52,14 +54,13 @@
>      uint32_t          obj_type;
>      struct timespec   mtime;
>      uint32_t          accessmask;
> -    int               datalength;
> +    off_t             datalength;
>      ...;
>  } val_attrs_t;
>
>  /* the exact layout of the above struct will be figured out during build time */
>
>  typedef int ... time_t;
> -typedef int ... off_t;
>
>  typedef struct timespec {
>      time_t tv_sec;
> _______________________________________________
> Mercurial-devel mailing list
> Mercurial-devel at mercurial-scm.org
> https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel


More information about the Mercurial-devel mailing list