소스 검색

Static analysis fix: Value stored to '[bcd]' is never read.

Ryan C. Gordon 11 년 전
부모
커밋
546cb8901e
1개의 변경된 파일5개의 추가작업 그리고 3개의 파일을 삭제
  1. 5 3
      src/cpuinfo/SDL_cpuinfo.c

+ 5 - 3
src/cpuinfo/SDL_cpuinfo.c

@@ -408,15 +408,17 @@ SDL_GetCPUType(void)
             SDL_CPUType[i++] = (char)(b & 0xff); b >>= 8;
             SDL_CPUType[i++] = (char)(b & 0xff); b >>= 8;
             SDL_CPUType[i++] = (char)(b & 0xff); b >>= 8;
-            SDL_CPUType[i++] = (char)(b & 0xff); b >>= 8;
-            SDL_CPUType[i++] = (char)(d & 0xff); d >>= 8;
+            SDL_CPUType[i++] = (char)(b & 0xff);
+
             SDL_CPUType[i++] = (char)(d & 0xff); d >>= 8;
             SDL_CPUType[i++] = (char)(d & 0xff); d >>= 8;
             SDL_CPUType[i++] = (char)(d & 0xff); d >>= 8;
+            SDL_CPUType[i++] = (char)(d & 0xff);
+
             SDL_CPUType[i++] = (char)(c & 0xff); c >>= 8;
             SDL_CPUType[i++] = (char)(c & 0xff); c >>= 8;
             SDL_CPUType[i++] = (char)(c & 0xff); c >>= 8;
-            SDL_CPUType[i++] = (char)(c & 0xff); c >>= 8;
+            SDL_CPUType[i++] = (char)(c & 0xff);
         }
         if (!SDL_CPUType[0]) {
             SDL_strlcpy(SDL_CPUType, "Unknown", sizeof(SDL_CPUType));