Alexander Ivchenko edd7c2ec25 Fix the printf issue for 64 bits. The following case:
printf("%1$s %1$s\n", "test");

would print garbage instead of the second "test". The problem is __find_arguments
and the patch is a backport of two patches from OpenBSD that fix the issue:

Author: tedu <tedu@cvs.openbsd.org>
Date:   Sat Apr 29 23:00:24 2006 +0000

    check mmap for failure.  the helper functions using it return -1, but
    callers do not yet check since printf() for example is not documented
    to return an error.
    some formatting cleanups.
    mostly ok deraadt millert

Author: millert <millert@cvs.openbsd.org>
Date:   Fri May 16 14:28:54 2008 +0000

    C99 says that for each va_copy() there must be a matching va_end().
    Replace the non-portable hackery in __find_arguments() with a union.
    From FreeBSD.

Change-Id: I6ea392ce6fcf4a319ae6a67ec58cc52fe7cbe534
Signed-off-by: Alexander Ivchenko <alexander.ivchenko@intel.com>
2014-04-02 18:30:55 +04:00
..
2013-12-03 18:42:41 -08:00
2013-12-03 18:42:41 -08:00
2013-02-01 14:51:19 -08:00
2014-02-24 20:22:11 +00:00
2013-10-29 14:55:11 -07:00
2014-02-12 19:04:27 -08:00
2014-02-21 16:27:21 +00:00
2013-02-13 14:40:48 -08:00
2014-02-24 15:55:31 -08:00
2014-01-09 11:00:04 -08:00
2014-01-03 14:49:37 -08:00
2014-02-24 20:22:11 +00:00
2014-03-26 17:57:48 +00:00
2014-03-04 00:58:31 +00:00