changeset 31915:c1e009d855b5

Avoid another unnecessary intermediate variable.
author reimar
date Sat, 21 Aug 2010 09:58:02 +0000
parents 579d0c6b4270
children 6b45e5fb9dc4
files stream/stream_bd.c
diffstat 1 files changed, 1 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/stream/stream_bd.c	Sat Aug 21 09:55:30 2010 +0000
+++ b/stream/stream_bd.c	Sat Aug 21 09:58:02 2010 +0000
@@ -163,7 +163,6 @@
         int i;
         char line[1024];
         char *vst;
-        unsigned int byte;
 
         stream_read_line(file, line, sizeof(line), 0);
         // file is built up this way:
@@ -188,9 +187,8 @@
         if (strlen(vst) < 32)
             continue;
         for (i = 0; i < 16; i++) {
-            if (sscanf(&vst[i*2], "%2x", &byte) != 1)
+            if (sscanf(&vst[i*2], "%2"SCNx8, &bd->vuk.u8[i]) != 1)
                 break;
-            bd->vuk.u8[i] = byte;
         }
         vukfound = 1;
     }