wicdec: silence some warnings

-Wformat, -Wmissing-field-initializers and size type related

Change-Id: I92b1c7cc485bf59f94b5c0f8bb2137d87604f831
This commit is contained in:
James Zern
2013-02-04 16:13:59 -08:00
parent 1f803f645d
commit e7ea61eb75
2 changed files with 31 additions and 21 deletions

View File

@ -70,10 +70,10 @@ typedef enum {
#define IFS(fn) \
do { \
if (SUCCEEDED(hr)) { \
hr = (fn); \
if (FAILED(hr)) fprintf(stderr, #fn " failed %08x\n", hr); \
} \
if (SUCCEEDED(hr)) { \
hr = (fn); \
if (FAILED(hr)) fprintf(stderr, #fn " failed %08lx\n", hr); \
} \
} while (0)
#ifdef __cplusplus
@ -86,8 +86,10 @@ static HRESULT CreateOutputStream(const char* out_file_name,
IStream** ppStream) {
HRESULT hr = S_OK;
IFS(SHCreateStreamOnFileA(out_file_name, STGM_WRITE | STGM_CREATE, ppStream));
if (FAILED(hr))
fprintf(stderr, "Error opening output file %s (%08x)\n", out_file_name, hr);
if (FAILED(hr)) {
fprintf(stderr, "Error opening output file %s (%08lx)\n",
out_file_name, hr);
}
return hr;
}