On Mon, Oct 5, 2009 at 5:09 PM, Paul Pluzhnikov <[email protected]> wrote:
> -static inline void
> +static inline int
> maps_init (struct map_iterator *mi, pid_t pid)
> {
> - char path[PATH_MAX], *cp;
> + char path[sizeof ("/proc/01234567879/maps")], *cp;
>
Did you mean 789 and not 7879 above?
There seems to be an implicit assumption that size of pid_t is <= 32
bits (which seems to be true for all archs supported by linux). Since
you have an assert to check that, I'm ok with this change.
> - if (i < buf_size - 1)
> + if (valp != NULL && i < buf_size - 1)
Prefer parens around expressions.
I'll go ahead and make these two changes and apply.
-Arun
_______________________________________________
Libunwind-devel mailing list
[email protected]
http://lists.nongnu.org/mailman/listinfo/libunwind-devel