This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: va_list and x86_64 possible bug (?)


On 10/17/07, Andrew Haley <aph-gcc@littlepinkcloud.com> wrote:
> Macy Gasp writes:
>  > Hi everybody,
>
> Read the Fine Manual:
>
>
>        int vsprintf(char *str, const char *format, va_list ap);
>
>        The functions vprintf(), vfprintf(), vsprintf(), vsnprintf()
>        are equivalent to the functions printf(), fprintf(), sprintf(),
>        snprintf(), respectively, except that they are called with a
>        va_list instead of a variable number of arguments. These
>        functions do not call the va_end macro. Consequently, the value
>        of ap is undefined after the call. The application should call
>        va_end(ap) itself afterwards.
>
>
> Andrew.
>

Thanks for the answer, I missed that part :( .
Thanks to the other Andrew too , for his answer :)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]