Author: axeld Date: 2010-08-29 23:34:35 +0200 (Sun, 29 Aug 2010) New Revision: 38432 Changeset: http://dev.haiku-os.org/changeset/38432 Modified: haiku/trunk/src/add-ons/kernel/file_systems/layers/attribute_overlay/attribute_overlay.cpp Log: * FindAttribute() was broken and would find partial names (ie. if an attribute with the name "abc" existed, it would be returned when opening any attribute starting with "abc". Modified: haiku/trunk/src/add-ons/kernel/file_systems/layers/attribute_overlay/attribute_overlay.cpp =================================================================== --- haiku/trunk/src/add-ons/kernel/file_systems/layers/attribute_overlay/attribute_overlay.cpp 2010-08-29 21:34:16 UTC (rev 38431) +++ haiku/trunk/src/add-ons/kernel/file_systems/layers/attribute_overlay/attribute_overlay.cpp 2010-08-29 21:34:35 UTC (rev 38432) @@ -766,8 +766,7 @@ AttributeFile::FindAttribute(const char *name, uint32 *index) { for (uint32 i = 0; i < fFile->entry_count; i++) { - if (strncmp(fEntries[i]->Name(), name, fEntries[i]->NameLength()) - == 0) { + if (strcmp(fEntries[i]->Name(), name) == 0) { if (index) *index = i;