]> git.eshelyaron.com Git - emacs.git/commitdiff
Fix compiler warnings in w32proc.c.
authorEli Zaretskii <eliz@gnu.org>
Sat, 27 Oct 2012 19:43:48 +0000 (21:43 +0200)
committerEli Zaretskii <eliz@gnu.org>
Sat, 27 Oct 2012 19:43:48 +0000 (21:43 +0200)
 src/w32proc.c (sys_spawnve): Avoid compiler warning about format mismatch.
 (timer_loop): Remove unused variable.

src/ChangeLog
src/w32proc.c

index 398d19fe6f21c1ec5d826ae548c39e7743246b46..7f0367610117a1014940ee0626c5735bed6eb033 100644 (file)
        for the timer.
        (timer_loop): Enter critical section when accessing ULONGLONG
        values of the itimer_data struct, as these accesses are no longer
-       atomic.  Call 'w32_get_timer_time' instead of 'clock'.
+       atomic.  Call 'w32_get_timer_time' instead of 'clock'.  Remove
+       unused variable.
        (init_timers): Initialize s_pfn_Get_Thread_Times.
        (start_timer_thread): Don't assign itimer->caller_thread here.
        (getitimer): Assign itimer->caller_thread here.
        (setitimer): Always call getitimer to get the value of ticks_now.
+       (sys_spawnve): Avoid compiler warning about format mismatch.
 
 2012-10-26  Eli Zaretskii  <eliz@gnu.org>
 
index af656f915c741d5accf4820ecae3062b9fa474ed..e2187d5242550e0be05c6123d61e9f0b5fd9bde8 100644 (file)
@@ -335,7 +335,6 @@ timer_loop (LPVOID arg)
   int sig = (which == ITIMER_REAL) ? SIGALRM : SIGPROF;
   CRITICAL_SECTION *crit = (which == ITIMER_REAL) ? &crit_real : &crit_prof;
   const DWORD max_sleep = MAX_SINGLE_SLEEP * 1000 / CLOCKS_PER_SEC;
-  int new_count = 0;
   HANDLE hth = (which == ITIMER_REAL) ? NULL : itimer->caller_thread;
 
   while (1)
@@ -1656,7 +1655,7 @@ sys_spawnve (int mode, char *cmdname, char **argv, char **envp)
       numenv++;
     }
   /* extra env vars... */
-  sprintf (ppid_env_var_buffer, "EM_PARENT_PROCESS_ID=%d",
+  sprintf (ppid_env_var_buffer, "EM_PARENT_PROCESS_ID=%lu",
           GetCurrentProcessId ());
   arglen += strlen (ppid_env_var_buffer) + 1;
   numenv++;