https://git.reactos.org/?p=reactos.git;a=commitdiff;h=7100fa88544611767d100…
commit 7100fa88544611767d1006287aec507cf693b7e9
Author: Katayama Hirofumi MZ <katayama.hirofumi.mz(a)gmail.com>
AuthorDate: Sat Aug 5 21:17:06 2023 +0900
Commit: GitHub <noreply(a)github.com>
CommitDate: Sat Aug 5 21:17:06 2023 +0900
[SHELL32] Move SheRemoveQuotesA/W to iconcache.cpp (#5529)
Follow-up to #5517 (358e45d). stubs.cpp is for stub functions only. CORE-9277
---
dll/win32/shell32/iconcache.cpp | 48 +++++++++++++++++++++++++++++++++++++++++
dll/win32/shell32/stubs.cpp | 40 ----------------------------------
2 files changed, 48 insertions(+), 40 deletions(-)
diff --git a/dll/win32/shell32/iconcache.cpp b/dll/win32/shell32/iconcache.cpp
index 9a55f0f9fc0..3da28ecd826 100644
--- a/dll/win32/shell32/iconcache.cpp
+++ b/dll/win32/shell32/iconcache.cpp
@@ -987,6 +987,54 @@ HICON WINAPI ExtractAssociatedIconW(HINSTANCE hInst, LPWSTR
lpIconPath, LPWORD l
return hIcon;
}
+/*************************************************************************
+ * SheRemoveQuotesA (SHELL32.@)
+ */
+EXTERN_C LPSTR
+WINAPI
+SheRemoveQuotesA(LPSTR psz)
+{
+ PCHAR pch;
+
+ if (*psz == '"')
+ {
+ for (pch = psz + 1; *pch && *pch != '"'; ++pch)
+ {
+ *(pch - 1) = *pch;
+ }
+
+ if (*pch == '"')
+ *(pch - 1) = ANSI_NULL;
+ }
+
+ return psz;
+}
+
+/*************************************************************************
+ * SheRemoveQuotesW (SHELL32.@)
+ *
+ * ExtractAssociatedIconExW uses this function.
+ */
+EXTERN_C LPWSTR
+WINAPI
+SheRemoveQuotesW(LPWSTR psz)
+{
+ PWCHAR pch;
+
+ if (*psz == L'"')
+ {
+ for (pch = psz + 1; *pch && *pch != L'"'; ++pch)
+ {
+ *(pch - 1) = *pch;
+ }
+
+ if (*pch == L'"')
+ *(pch - 1) = UNICODE_NULL;
+ }
+
+ return psz;
+}
+
/*************************************************************************
* ExtractAssociatedIconExW (SHELL32.@)
*
diff --git a/dll/win32/shell32/stubs.cpp b/dll/win32/shell32/stubs.cpp
index ec1da6daf41..f3c79305971 100644
--- a/dll/win32/shell32/stubs.cpp
+++ b/dll/win32/shell32/stubs.cpp
@@ -440,46 +440,6 @@ SheSetCurDrive(INT iIndex)
return 1;
}
-EXTERN_C LPWSTR
-WINAPI
-SheRemoveQuotesW(LPWSTR psz)
-{
- PWCHAR pch;
-
- if (*psz == L'"')
- {
- for (pch = psz + 1; *pch && *pch != L'"'; ++pch)
- {
- *(pch - 1) = *pch;
- }
-
- if (*pch == L'"')
- *(pch - 1) = UNICODE_NULL;
- }
-
- return psz;
-}
-
-EXTERN_C LPSTR
-WINAPI
-SheRemoveQuotesA(LPSTR psz)
-{
- PCHAR pch;
-
- if (*psz == '"')
- {
- for (pch = psz + 1; *pch && *pch != '"'; ++pch)
- {
- *(pch - 1) = *pch;
- }
-
- if (*pch == '"')
- *(pch - 1) = ANSI_NULL;
- }
-
- return psz;
-}
-
/*
* Unimplemented
*/