Huge thanks to our Platinum Members Endace and LiveAction,
and our Silver Member Veeam, for supporting the Wireshark Foundation and project.

Wireshark-dev: Re: [Wireshark-dev] [Wireshark-commits] rev 25171: /trunk/epan/dissectors/ /trun

From: "Luis EG Ontanon" <luis@xxxxxxxxxxx>
Date: Sat, 26 Apr 2008 03:45:17 +0200
On Sat, Apr 26, 2008 at 3:34 AM, Jeff Morriss <jeff.morriss.ws@xxxxxxxxx> wrote:
>
> I get what he's saying but I just don't get it:  why would the compiler
> convert from int to unsigned short *before* it has to send the value into
> the call to dowork()?  E.g., 'x' should be an int until I (explicitly or
> implicitly) cast it to something else, non?  Actually it should still be an
> int after the call to dowork(); it just won't be an int when dowork() gets
> it.
>
> Maybe I need to go back to school because I'm feeling very noobish right
> now.

function arguments are automatically cast when passed, you can see the
reason why this is done  in printf when you pass a long long instead
of an int for a %i or a %d.

-- 
This information is top security. When you have read it, destroy yourself.
-- Marshall McLuhan