Fixes for -Wmissing-declaration and -Wwrite-string warnings.
This commit is contained in:
parent
7e44db5c41
commit
9f92ead47f
|
@ -38,10 +38,10 @@ const char* TEST_URL_2 = "http://localhost:8080/tests%2e.html?date=Mon%2010/10/1
|
|||
const char* TEST_URL_3 = "http://foo:bar@localhost:21/internal.php?query=x&return=y";
|
||||
|
||||
typedef struct _TEST_URL_CANONICALIZE {
|
||||
char *url;
|
||||
const char *url;
|
||||
DWORD flags;
|
||||
HRESULT expectret;
|
||||
char *expecturl;
|
||||
const char *expecturl;
|
||||
} TEST_URL_CANONICALIZE;
|
||||
|
||||
const TEST_URL_CANONICALIZE TEST_CANONICALIZE[] = {
|
||||
|
@ -67,11 +67,11 @@ const TEST_URL_CANONICALIZE TEST_CANONICALIZE[] = {
|
|||
};
|
||||
|
||||
typedef struct _TEST_URL_ESCAPE {
|
||||
char *url;
|
||||
const char *url;
|
||||
DWORD flags;
|
||||
DWORD expectescaped;
|
||||
HRESULT expectret;
|
||||
char *expecturl;
|
||||
const char *expecturl;
|
||||
} TEST_URL_ESCAPE;
|
||||
|
||||
const TEST_URL_ESCAPE TEST_ESCAPE[] = {
|
||||
|
@ -156,11 +156,11 @@ const TEST_URL_ESCAPE TEST_ESCAPE[] = {
|
|||
};
|
||||
|
||||
typedef struct _TEST_URL_COMBINE {
|
||||
char *url1;
|
||||
char *url2;
|
||||
const char *url1;
|
||||
const char *url2;
|
||||
DWORD flags;
|
||||
HRESULT expectret;
|
||||
char *expecturl;
|
||||
const char *expecturl;
|
||||
} TEST_URL_COMBINE;
|
||||
|
||||
const TEST_URL_COMBINE TEST_COMBINE[] = {
|
||||
|
@ -178,8 +178,8 @@ const TEST_URL_COMBINE TEST_COMBINE[] = {
|
|||
};
|
||||
|
||||
struct {
|
||||
char *path;
|
||||
char *url;
|
||||
const char *path;
|
||||
const char *url;
|
||||
DWORD ret;
|
||||
} TEST_URLFROMPATH [] = {
|
||||
{"foo", "file:foo", S_OK},
|
||||
|
@ -198,8 +198,8 @@ struct {
|
|||
};
|
||||
|
||||
struct {
|
||||
char *url;
|
||||
char *path;
|
||||
const char *url;
|
||||
const char *path;
|
||||
DWORD ret;
|
||||
} TEST_PATHFROMURL[] = {
|
||||
{"file:///c:/foo/ba%5Cr", "c:\\foo\\ba\\r", S_OK},
|
||||
|
@ -232,8 +232,8 @@ struct {
|
|||
};
|
||||
|
||||
struct {
|
||||
char *url;
|
||||
char *expect;
|
||||
char url[30];
|
||||
const char *expect;
|
||||
} TEST_URL_UNESCAPE[] = {
|
||||
{"file://foo/bar", "file://foo/bar"},
|
||||
{"file://fo%20o%5Ca/bar", "file://fo o\\a/bar"}
|
||||
|
@ -241,7 +241,7 @@ struct {
|
|||
|
||||
|
||||
struct {
|
||||
char *path;
|
||||
const char *path;
|
||||
BOOL expect;
|
||||
} TEST_PATH_IS_URL[] = {
|
||||
{"http://foo/bar", TRUE},
|
||||
|
@ -254,7 +254,7 @@ struct {
|
|||
};
|
||||
|
||||
struct {
|
||||
char *url;
|
||||
const char *url;
|
||||
BOOL expectOpaque;
|
||||
BOOL expectFile;
|
||||
} TEST_URLIS_ATTRIBS[] = {
|
||||
|
|
|
@ -484,8 +484,6 @@ static void test_StrDupA()
|
|||
|
||||
static void test_StrFormatByteSize64A(void)
|
||||
{
|
||||
/* this test fails on locales which do not use '.' as a decimal separator */
|
||||
#if 0
|
||||
char szBuff[256];
|
||||
const StrFormatSizeResult* result = StrFormatSize_results;
|
||||
|
||||
|
@ -499,13 +497,10 @@ static void test_StrFormatByteSize64A(void)
|
|||
|
||||
result++;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
static void test_StrFormatKBSizeW(void)
|
||||
{
|
||||
/* FIXME: Awaiting NLS fixes in kernel before these succeed */
|
||||
#if 0
|
||||
WCHAR szBuffW[256];
|
||||
char szBuff[256];
|
||||
const StrFormatSizeResult* result = StrFormatSize_results;
|
||||
|
@ -519,13 +514,10 @@ static void test_StrFormatKBSizeW(void)
|
|||
(LONG)(result->value >> 32), (LONG)result->value, szBuff, result->kb_size);
|
||||
result++;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
static void test_StrFormatKBSizeA(void)
|
||||
{
|
||||
/* this test fails on locales which do not use '.' as a decimal separator */
|
||||
#if 0
|
||||
char szBuff[256];
|
||||
const StrFormatSizeResult* result = StrFormatSize_results;
|
||||
|
||||
|
@ -538,10 +530,9 @@ static void test_StrFormatKBSizeA(void)
|
|||
(LONG)(result->value >> 32), (LONG)result->value, szBuff, result->kb_size);
|
||||
result++;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
void test_StrFromTimeIntervalA(void)
|
||||
static void test_StrFromTimeIntervalA(void)
|
||||
{
|
||||
char szBuff[256];
|
||||
const StrFromTimeIntervalResult* result = StrFromTimeInterval_results;
|
||||
|
@ -556,7 +547,7 @@ void test_StrFromTimeIntervalA(void)
|
|||
}
|
||||
}
|
||||
|
||||
void test_StrCmpA(void)
|
||||
static void test_StrCmpA(void)
|
||||
{
|
||||
static const char str1[] = {'a','b','c','d','e','f'};
|
||||
static const char str2[] = {'a','B','c','d','e','f'};
|
||||
|
@ -582,7 +573,7 @@ void test_StrCmpA(void)
|
|||
ok(!pIntlStrEqWorkerA(TRUE, str1, str2, 5), "pIntlStrEqWorkerA(TRUE,...) isn't case-sensitive\n");
|
||||
}
|
||||
|
||||
void test_StrCmpW(void)
|
||||
static void test_StrCmpW(void)
|
||||
{
|
||||
static const WCHAR str1[] = {'a','b','c','d','e','f'};
|
||||
static const WCHAR str2[] = {'a','B','c','d','e','f'};
|
||||
|
@ -747,9 +738,17 @@ START_TEST(string)
|
|||
test_StrToIntExA();
|
||||
test_StrToIntExW();
|
||||
test_StrDupA();
|
||||
if (0)
|
||||
{
|
||||
/* this test fails on locales which do not use '.' as a decimal separator */
|
||||
test_StrFormatByteSize64A();
|
||||
|
||||
/* this test fails on locales which do not use '.' as a decimal separator */
|
||||
test_StrFormatKBSizeA();
|
||||
|
||||
/* FIXME: Awaiting NLS fixes in kernel before these succeed */
|
||||
test_StrFormatKBSizeW();
|
||||
}
|
||||
test_StrFromTimeIntervalA();
|
||||
test_StrCmpA();
|
||||
test_StrCmpW();
|
||||
|
|
Loading…
Reference in New Issue