Thanks all for replying and giving suggestions. I've sent two patches in another thread, and I've already setup git send-email, cool! It's way easy to send patches on command lines.<br><br>Personally, I'd like to use PRI-prefix, because it looks more standard. But casting and stick it with %llx should be OK for all platforms.<div>
<br></div><div>Thanks!</div><div><br><div class="gmail_quote">在 2012年3月22日 下午8:08,John Haxby <span dir="ltr"><<a href="mailto:jch@thehaxbys.co.uk">jch@thehaxbys.co.uk</a>></span>写道:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="im">On 22/03/12 08:58, Tanu Kaskinen wrote:<br>
> On Wed, 2012-03-21 at 16:21 +0100, David Henningsson wrote:<br>
><br>
>> ><br>
</div><div class="im">>> > A quick grep through the code shows that this is how we've been doing it<br>
>> > up till now, so we should probably keep it that way for consistency.<br>
>> ><br>
>> > So, just for education, would you mind resending the patch with git<br>
>> > send-email, and using %llx ? Thanks!<br>
> At the risk of turning this into prolonged bikeshedding, IMO the PRI<br>
> constants would be the better solution (with a small margin). I have<br>
> myself used the casting solution in the past to get rid of compiler<br>
> warnings, but that has been because I didn't know about the PRI<br>
> constants.<br>
<br>
</div>Just sticking my oar in here :)<br>
<br>
The PRI constants are the right way to do it. You can get away with<br>
casts and %llx (or whatever) almost all the time.<br>
<br>
The trouble is the "almost all". Sooner or later you're going to get<br>
something breaking either because %llx turns out to be wrong or because<br>
the cast turns out to be wrong and the compiler has explicitly been told<br>
not to notice. Change it to PRI and let the compiler do its job; you<br>
won't regret it in the long run.<br>
<br>
jch<br>
_______________________________________________<br>
pulseaudio-discuss mailing list<br>
<a href="mailto:pulseaudio-discuss@lists.freedesktop.org">pulseaudio-discuss@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/pulseaudio-discuss" target="_blank">http://lists.freedesktop.org/mailman/listinfo/pulseaudio-discuss</a><br>
</blockquote></div><br></div>