:
:Is there a trick to calling malloc from NASM code?  It links fine and steps
:into malloc() fine, but returns a NULL pointer.

    Nope, should work just fine.  The assembly should look something like
    this (assuming we are talking about a userland program here):

    pushl       $bytes_to_malloc
    call        malloc
    addl        $4,%esp
    [ returns pointer in %eax ]

                                        -Matt
                                        Matthew Dillon 
                                        <[EMAIL PROTECTED]>

Reply via email to