merge with stable
authorMatt Mackall <mpm@selenic.com>
Sun, 20 May 2012 14:40:36 -0500
changeset 16755 d0b9ebba41e9
parent 16754 d94c470c3deb (current diff)
parent 16748 0a730d3c5aae (diff)
child 16756 2e3513e7348a
merge with stable
mercurial/revset.py
--- a/mercurial/osutil.c	Sun May 20 14:37:22 2012 -0500
+++ b/mercurial/osutil.c	Sun May 20 14:40:36 2012 -0500
@@ -331,6 +331,9 @@
 			err = lstat(fullpath, &st);
 #endif
 			if (err == -1) {
+				/* race with file deletion? */
+				if (errno == ENOENT)
+					continue;
 				strncpy(fullpath + pathlen + 1, ent->d_name,
 					PATH_MAX - pathlen);
 				fullpath[PATH_MAX] = 0;
--- a/mercurial/revset.py	Sun May 20 14:37:22 2012 -0500
+++ b/mercurial/revset.py	Sun May 20 14:40:36 2012 -0500
@@ -867,6 +867,10 @@
     """``present(set)``
     An empty set, if any revision in set isn't found; otherwise,
     all revisions in set.
+
+    If any of specified revisions is not present in the local repository,
+    the query is normally aborted. But this predicate allows the query
+    to continue even in such cases.
     """
     try:
         return getset(repo, subset, x)