Re: [PATCH 2/9 v2] Introduce nat/linux-namespaces.[ch]

Pedro Alves
2015-06-11T11:04:44Z

On 06/11/2015 09:40 AM, James Greenhalgh wrote:

> I would expect that to mean this is broken for any
> "long int != ssize_t" target. I'm not sure which C standards GDB requires
> compatability with, but I believe the portable C99 way of printing a
> ssize_t would be "%zd".

GDB is written in C90 currently.

The usual way to handle this is to use plongest (with %s). As this
is native GNU/Linux code, casting to long (thus keep %ld) would
be fine too.

Thanks,
Pedro Alves