> email@example.com writes:
>>Fix crash in svn status -u when an unversioned and ignored directory
>>is in the repository.
>>Found by: Stefan Küng <firstname.lastname@example.org>
>>* subversion/libsvn_wc/status.c (make_dir_baton): Don't try to get status
>> of ignored directory.
>> (status_ignored_dir): New test.
>> (test_list): Run it.
> The log says the crash happens "when an unversioned and ignored
> directory is in the repository".
> First, did you mean "working copy" instead of "repository"? :-)
> Second, a question about the code, see below...
>>--- trunk/subversion/libsvn_wc/status.c (original)
>>+++ trunk/subversion/libsvn_wc/status.c Mon Jan 30 08:32:54 2006
>>@@ -1155,13 +1155,14 @@
>> /* Order is important here. We can't depend on parent_status->entry
>> being non-NULL until after we've checked all the conditions that
>> might indicate that the parent is unversioned ("unversioned" for
>>- our purposes includes being an external). */
>>+ our purposes includes being an external or ignored item). */
>> if (parent_status
>> && (parent_status->text_status != svn_wc_status_unversioned)
>> && (parent_status->text_status != svn_wc_status_deleted)
>> && (parent_status->text_status != svn_wc_status_missing)
>> && (parent_status->text_status != svn_wc_status_obstructed)
>> && (parent_status->text_status != svn_wc_status_external)
>>+ && (parent_status->text_status != svn_wc_status_ignored)
>> && (parent_status->entry->kind == svn_node_dir)
>> && (eb->descend || (! pb)))
> This conditional gets the entry's status if parent_status is *neither*
> unversioned nor ignored. Is it the case that if an object is both
> ignored and unversioned, its text_status will be 'ignored' not
> 'unversioned'? In other words, the crash was happening because even
> though the item *was* unversioned, the 'ignore' part dominated, so the
> text_status said nothing about its being unversioned?
I believe the status "..._ignored" denotes a sub-set of unversioned items, and
"..._unversioned" the rest of the unversioned items. Therefore, yes, the
status of such an item will be "..._ignored".
Since this is not entirely obvious, and furthermore I remember getting confused
by it (possibly by the corresponding output of "svn status" at the user level)
when I was new to Subversion, I think we want a comment somewhere. How about this:
Clarify that the "ignored" status only applies to unversioned items.
(svn_wc_status_ignored): Expand the doc string.
--- subversion/include/svn_wc.h (revision 18266)
+++ subversion/include/svn_wc.h (working copy)
@@ -1612,7 +1612,7 @@
/** local mods received conflicting repos mods */
- /** a resource marked as ignored */
+ /** is unversioned but configured to be ignored */
/** an unversioned resource is in the way of the versioned resource */
To unsubscribe, e-mail: email@example.com
For additional commands, e-mail: firstname.lastname@example.org
Received on Mon Jan 30 18:37:21 2006