[MPlayer-dev-eng] [PATCH 2/4] String handling audit/cleanup

Nico Sabbi nicola_sabbi at fastwebnet.it
Sun Mar 4 09:56:07 CET 2007


Reimar Döffinger wrote:
> Hello,
> On Sat, Mar 03, 2007 at 05:26:46PM +0100, Nico Sabbi wrote:
> 
>>yes, but this is much better
>>
>>Index: stream_dvd.c
>>===================================================================
>>--- stream_dvd.c        (revisione 22422)
>>+++ stream_dvd.c        (copia locale)
>>@@ -867,10 +867,10 @@
>>      if (DVDDiscID(dvd, discid) >= 0)
>>      {
>>        int i;
>>-        char buf[33];
>>+        mp_msg(MSGT_IDENTIFY, MSGL_V, "ID_DVD_DISC_ID=");
>>        for (i = 0; i < 16; i ++)
>>-          sprintf(buf+2*i, "%02X", discid[i]);
>>-        mp_msg(MSGT_IDENTIFY, MSGL_V, "ID_DVD_DISC_ID=%s\n", buf);
>>+          mp_msg(MSGT_IDENTIFY, MSGL_V, "%02X", discid[i]);
>>+        mp_msg(MSGT_IDENTIFY, MSGL_V, "\n");
>>      }
>>    }
>>    /**
> 
> 
> I think this is the best solution for these things, but I'd still like
> to mention that it might mess up things a bit with the color console
> (though that could and should be fixed in mp_msg.c if anything).
> 

applied. Why printing %X numbers messes up the color console?

-- 
"Without a frontend, mplayer is useless" - someone in mplayer-users




More information about the MPlayer-dev-eng mailing list