Changeset 370 for branches/samba-3.3.x/source/smbd/mangle_hash.c
- Timestamp:
- Jan 15, 2010, 8:23:30 AM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/samba-3.3.x/source/smbd/mangle_hash.c
r206 r370 433 433 /* Truncate at the '.' */ 434 434 *s1 = '\0'; 435 /* 436 * DANGER WILL ROBINSON - this 437 * is changing a const string via 438 * an aliased pointer ! Remember to 439 * put it back once we've used it. 440 * JRA 441 */ 435 442 *s2 = '\0'; 436 443 } … … 444 451 DEBUG(5,("cache_mangled_name: Stored entry %s -> %s\n", mangled_name_key, raw_name)); 445 452 } 453 /* Restore the change we made to the const string. */ 454 *s2 = '.'; 446 455 } 447 456 … … 614 623 status = is_valid_name(name_ucs2, False, False); 615 624 SAFE_FREE(name_ucs2); 616 return NT_STATUS_IS_OK(status); 625 /* We return true if we *must* mangle, so if it's 626 * a valid name (status == OK) then we must return 627 * false. Bug #6939. */ 628 return !NT_STATUS_IS_OK(status); 617 629 } 618 630
Note:
See TracChangeset
for help on using the changeset viewer.