Module: wine
Branch: master
Commit: 16e9c35910ae78a8c5cd7a5c11da4cf75b9ddf7b
URL: http://source.winehq.org/git/wine.git/?a=commit;h=16e9c35910ae78a8c5cd7a5c1…
Author: Andrew Talbot <Andrew.Talbot(a)talbotville.com>
Date: Thu Jul 26 22:24:58 2007 +0100
oleaut32: Constify some variables.
---
dlls/oleaut32/typelib2.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/dlls/oleaut32/typelib2.c b/dlls/oleaut32/typelib2.c
index 874d8a8..41ee8e6 100644
--- a/dlls/oleaut32/typelib2.c
+++ b/dlls/oleaut32/typelib2.c
@@ -322,7 +322,7 @@ static int ctl2_find_guid(
*/
static int ctl2_find_name(
ICreateTypeLib2Impl *This, /* [I] The typelib to operate against. */
- char *name) /* [I] The encoded name to find. */
+ const char *name) /* [I] The encoded name to find. */
{
int offset;
int *namestruct;
@@ -331,7 +331,7 @@ static int ctl2_find_name(
while (offset != -1) {
namestruct = (int *)&This->typelib_segment_data[MSFT_SEG_NAME][offset];
- if (!((namestruct[2] ^ *((int *)name)) & 0xffff00ff)) {
+ if (!((namestruct[2] ^ *((const int *)name)) & 0xffff00ff)) {
/* hash codes and lengths match, final test */
if (!strncasecmp(name+4, (void *)(namestruct+3), name[0])) break;
}
@@ -828,7 +828,7 @@ static HRESULT ctl2_set_custdata(
*/
static int ctl2_encode_typedesc(
ICreateTypeLib2Impl *This, /* [I] The type library in which to encode the TYPEDESC. */
- TYPEDESC *tdesc, /* [I] The type description to encode. */
+ const TYPEDESC *tdesc, /* [I] The type description to encode. */
int *encoded_tdesc, /* [O] The encoded type description. */
int *width, /* [O] The width of the type, or NULL. */
int *alignment, /* [O] The alignment of the type, or NULL. */
@@ -3225,7 +3225,7 @@ static HRESULT WINAPI ICreateTypeLib2_fnSetLibFlags(ICreateTypeLib2 * iface, UIN
return S_OK;
}
-static int ctl2_write_chunk(HANDLE hFile, void *segment, int length)
+static int ctl2_write_chunk(HANDLE hFile, const void *segment, int length)
{
DWORD dwWritten;
if (!WriteFile(hFile, segment, length, &dwWritten, 0)) {