OSDN Git Service

[Fix] #37353 コンパイル警告修正 / Fixed compilation warnings
authorHourier <hourier@users.sourceforge.jp>
Sat, 1 Feb 2020 04:20:30 +0000 (13:20 +0900)
committerHourier <hourier@users.sourceforge.jp>
Sat, 1 Feb 2020 04:20:30 +0000 (13:20 +0900)
src/main-win.c
src/util.c

index 074e2b0..dc354d7 100644 (file)
@@ -4696,11 +4696,13 @@ static void init_stuff(void)
 
 
 /*!
+ * todo よく見るとhMutexはちゃんと使われていない……?
  * @brief (Windows固有)変愚蛮怒が起動済かどうかのチェック
  */
 static bool is_already_running(void)
 {
-       HANDLE hMutex = CreateMutex(NULL, TRUE, VERSION_NAME);
+       HANDLE hMutex;
+       hMutex = CreateMutex(NULL, TRUE, VERSION_NAME);
        if (GetLastError() == ERROR_ALREADY_EXISTS)
        {
                return TRUE;
index 7108e3a..5d69579 100644 (file)
@@ -1882,7 +1882,7 @@ void message_add(concptr str)
 
        if (!str) return;
 
-       int n = strlen(str);
+       u32b n = strlen(str);
        if (n >= MESSAGE_BUF / 4) return;
 
        if (n > 80)