From fa5ea2ec6d695bda86e18d33a2ab907a32f9057b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jurko=20Gospodneti=C4=87?= Date: Thu, 5 Jul 2012 08:00:13 +0000 Subject: [PATCH] Boost Jam cleanup - removed one extra object copy in path_key(). [SVN r79279] --- v2/engine/pathunix.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/v2/engine/pathunix.c b/v2/engine/pathunix.c index 6b0b6b6ea..f1357e3f2 100644 --- a/v2/engine/pathunix.c +++ b/v2/engine/pathunix.c @@ -398,7 +398,7 @@ static path_key_entry * path_key( OBJECT * const path, &found ); if ( !found || nresult == result ) { - nresult->path = object_copy( normalized ); + nresult->path = normalized; if ( known_to_be_long ) nresult->key = object_copy( path ); else @@ -410,8 +410,9 @@ static path_key_entry * path_key( OBJECT * const path, string_free( long_path ); } } + else + object_free( normalized ); string_free( buf ); - object_free( normalized ); if ( nresult != result ) { result->path = object_copy( path );