From 602e0df9f62be3e119a521962f930af2cc904776 Mon Sep 17 00:00:00 2001 From: Andrew Talbot Date: Wed, 16 Aug 2006 20:14:08 +0100 Subject: [PATCH] regedit: Write-strings warnings fix. --- programs/regedit/childwnd.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/programs/regedit/childwnd.c b/programs/regedit/childwnd.c index c284d8858c..49adfd167e 100644 --- a/programs/regedit/childwnd.c +++ b/programs/regedit/childwnd.c @@ -128,9 +128,10 @@ static LPTSTR GetPathRoot(HWND hwndTV, HTREEITEM hItem, BOOL bFull) { } LPTSTR GetItemFullPath(HWND hwndTV, HTREEITEM hItem, BOOL bFull) { - LPTSTR parts[2] = {_T(""), _T("")}; - HKEY hRootKey = NULL; + LPTSTR parts[2]; LPTSTR ret; + HKEY hRootKey = NULL; + parts[0] = GetPathRoot(hwndTV, hItem, bFull); parts[1] = GetItemPath(hwndTV, hItem, &hRootKey); ret = CombinePaths((LPCTSTR *)parts, 2); @@ -139,7 +140,9 @@ LPTSTR GetItemFullPath(HWND hwndTV, HTREEITEM hItem, BOOL bFull) { } LPTSTR GetPathFullPath(HWND hwndTV, LPTSTR path) { - LPTSTR parts[2] = {_T(""), _T("")}, ret; + LPTSTR parts[2]; + LPTSTR ret; + parts[0] = GetPathRoot(hwndTV, 0, TRUE); parts[1] = path; ret = CombinePaths((LPCTSTR *)parts, 2);