Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re: XS on 64-bit: Warning from sv_vsetpvf call

by almut (Canon)
on Jun 27, 2008 at 01:55 UTC ( [id://694302]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    int printf_handler(const char *format, va_list args)
    {
        ...
        sv_vsetpvf(printf_str, format, &args);
        ...
    
  2. or download this
    int printf_handler(const char *format, va_list* args)
    {
        ...
        sv_vsetpvf(printf_str, format, args);
        ...
    
  3. or download this
    #include <stdarg.h>
    #include <stdio.h>
    ...
        vatest("%s: %s,%s", argv[0], msg1, msg2);  // three args
        return 0;
    }
    
  4. or download this
    $ gcc -Wall vatest.c -o vatest
    vatest.c: In function `vatest_':
    ...
    Segmentation fault
    $ file vatest
    vatest: ELF 64-bit LSB executable, AMD x86-64, version 1 (SYSV), for G
    +NU/Linux 2.6.4, dynamically linked (uses shared libs), for GNU/Linux 
    +2.6.4, not stripped
    
  5. or download this
    ...
    void vatest_(char* format, va_list* args) {
    ...
        va_end (args);
    }
    ...
    
  6. or download this
    $ gcc -Wall vatest.c -o vatest
    $ ./vatest
    ./vatest: foo: Success
    ./vatest: foo,bar: Success
    

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://694302]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (6)
As of 2024-04-19 13:15 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found