IMHO, correct usage is

Print (L"0x%.16lx", Value); // lower case L

On Fri, Oct 17, 2014 at 2:22 PM,  <[email protected]> wrote:
> Hi,
>
> I tried to print a UINT64 value as follows and hoped to get output
> “0x1122334455667788”:
>
> {
>
>   UINT64 Value = 0x1122334455667788;
>
>   Print(L“0x%.16x”, Value);
>
> }
>
>
>
> The actual output is “0x0000000055667788” though. The leading 4 bytes seem
> to get lost in cast to unsigned int in BasePrintLibVSPrint, line 320.
>
> See
> https://github.com/tianocore/edk2/blob/master/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BasePrintLib/PrintLib.c
>
>
>
> As a workaround I now use Print(L“0x%.8x%.8x”, Value >> 32, Value) but I
> would prefer to use Print(L“0x%.16x”, Value).
>
>
>
> Thanks and Regards,
>
> Stefan
>
>
> ------------------------------------------------------------------------------
> Comprehensive Server Monitoring with Site24x7.
> Monitor 10 servers for $9/Month.
> Get alerted through email, SMS, voice calls or mobile push notifications.
> Take corrective actions from your mobile device.
> http://p.sf.net/sfu/Zoho
> _______________________________________________
> edk2-devel mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/edk2-devel
>

------------------------------------------------------------------------------
Comprehensive Server Monitoring with Site24x7.
Monitor 10 servers for $9/Month.
Get alerted through email, SMS, voice calls or mobile push notifications.
Take corrective actions from your mobile device.
http://p.sf.net/sfu/Zoho
_______________________________________________
edk2-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/edk2-devel

Reply via email to