diff options
| author | Paul Eggert | 2011-03-14 18:19:50 -0700 |
|---|---|---|
| committer | Paul Eggert | 2011-03-14 18:19:50 -0700 |
| commit | b3dd38aba98f3521d164ef698d6b77b80d867fb8 (patch) | |
| tree | 2dd84c2ae762bc0990dbea23d2fd8f7c2ee0ae93 /src | |
| parent | 03d78a21befef9074bd85bba98968e9c25e022af (diff) | |
| download | emacs-b3dd38aba98f3521d164ef698d6b77b80d867fb8.tar.gz emacs-b3dd38aba98f3521d164ef698d6b77b80d867fb8.zip | |
* filelock.c (lock_file_1): Rename local to avoid shadowing.
Diffstat (limited to 'src')
| -rw-r--r-- | src/ChangeLog | 1 | ||||
| -rw-r--r-- | src/filelock.c | 8 |
2 files changed, 5 insertions, 4 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index 25935defc9b..0f6bd3dab9c 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,6 +1,7 @@ | |||
| 1 | 2011-03-15 Paul Eggert <eggert@cs.ucla.edu> | 1 | 2011-03-15 Paul Eggert <eggert@cs.ucla.edu> |
| 2 | 2 | ||
| 3 | * filelock.c (within_one_second): Now static. | 3 | * filelock.c (within_one_second): Now static. |
| 4 | (lock_file_1): Rename local to avoid shadowing. | ||
| 4 | 5 | ||
| 5 | * buffer.c (fix_overlays_before): Mark locals as initialized. | 6 | * buffer.c (fix_overlays_before): Mark locals as initialized. |
| 6 | (fix_start_end_in_overlays): Likewise. This function should be | 7 | (fix_start_end_in_overlays): Likewise. This function should be |
diff --git a/src/filelock.c b/src/filelock.c index 0e4cee3c844..2138eaa502b 100644 --- a/src/filelock.c +++ b/src/filelock.c | |||
| @@ -344,13 +344,13 @@ static int | |||
| 344 | lock_file_1 (char *lfname, int force) | 344 | lock_file_1 (char *lfname, int force) |
| 345 | { | 345 | { |
| 346 | register int err; | 346 | register int err; |
| 347 | time_t boot_time; | 347 | time_t boot; |
| 348 | const char *user_name; | 348 | const char *user_name; |
| 349 | const char *host_name; | 349 | const char *host_name; |
| 350 | char *lock_info_str; | 350 | char *lock_info_str; |
| 351 | 351 | ||
| 352 | /* Call this first because it can GC. */ | 352 | /* Call this first because it can GC. */ |
| 353 | boot_time = get_boot_time (); | 353 | boot = get_boot_time (); |
| 354 | 354 | ||
| 355 | if (STRINGP (Fuser_login_name (Qnil))) | 355 | if (STRINGP (Fuser_login_name (Qnil))) |
| 356 | user_name = SSDATA (Fuser_login_name (Qnil)); | 356 | user_name = SSDATA (Fuser_login_name (Qnil)); |
| @@ -363,9 +363,9 @@ lock_file_1 (char *lfname, int force) | |||
| 363 | lock_info_str = (char *)alloca (strlen (user_name) + strlen (host_name) | 363 | lock_info_str = (char *)alloca (strlen (user_name) + strlen (host_name) |
| 364 | + LOCK_PID_MAX + 30); | 364 | + LOCK_PID_MAX + 30); |
| 365 | 365 | ||
| 366 | if (boot_time) | 366 | if (boot) |
| 367 | sprintf (lock_info_str, "%s@%s.%lu:%lu", user_name, host_name, | 367 | sprintf (lock_info_str, "%s@%s.%lu:%lu", user_name, host_name, |
| 368 | (unsigned long) getpid (), (unsigned long) boot_time); | 368 | (unsigned long) getpid (), (unsigned long) boot); |
| 369 | else | 369 | else |
| 370 | sprintf (lock_info_str, "%s@%s.%lu", user_name, host_name, | 370 | sprintf (lock_info_str, "%s@%s.%lu", user_name, host_name, |
| 371 | (unsigned long) getpid ()); | 371 | (unsigned long) getpid ()); |