]> code.delx.au - gnu-emacs/blobdiff - src/filelock.c
MAINTAINERS: Add myself for ERC and tq.el
[gnu-emacs] / src / filelock.c
index 689a80a4209cab29e1df1377b6c0f86985e1a460..4c211bf99471968cb5e19496719d76b4c88c8d98 100644 (file)
@@ -6,7 +6,7 @@ This file is part of GNU Emacs.
 
 GNU Emacs is free software; you can redistribute it and/or modify
 it under the terms of the GNU General Public License as published by
 
 GNU Emacs is free software; you can redistribute it and/or modify
 it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
+the Free Software Foundation; either version 3, or (at your option)
 any later version.
 
 GNU Emacs is distributed in the hope that it will be useful,
 any later version.
 
 GNU Emacs is distributed in the hope that it will be useful,
@@ -468,8 +468,8 @@ current_lock_owner (owner, lfname)
     }
 
   /* Parse USER@HOST.PID:BOOT_TIME.  If can't parse, return -1.  */
     }
 
   /* Parse USER@HOST.PID:BOOT_TIME.  If can't parse, return -1.  */
-  /* The USER is everything before the first @.  */
-  at = index (lfinfo, '@');
+  /* The USER is everything before the last @.  */
+  at = rindex (lfinfo, '@');
   dot = rindex (lfinfo, '.');
   if (!at || !dot)
     {
   dot = rindex (lfinfo, '.');
   if (!at || !dot)
     {