Commit 806be361 authored by Juan Lang's avatar Juan Lang Committed by Alexandre Julliard

Turn handled errors from ERRs to WARNs or TRACEs.

parent f23e8fec
...@@ -229,13 +229,13 @@ static UINT read_stream_data( IStorage *stg, LPCWSTR stname, ...@@ -229,13 +229,13 @@ static UINT read_stream_data( IStorage *stg, LPCWSTR stname,
r = IStream_Stat(stm, &stat, STATFLAG_NONAME ); r = IStream_Stat(stm, &stat, STATFLAG_NONAME );
if( FAILED( r ) ) if( FAILED( r ) )
{ {
ERR("open stream failed r = %08lx!\n",r); WARN("open stream failed r = %08lx!\n",r);
goto end; goto end;
} }
if( stat.cbSize.QuadPart >> 32 ) if( stat.cbSize.QuadPart >> 32 )
{ {
ERR("Too big!\n"); WARN("Too big!\n");
goto end; goto end;
} }
...@@ -243,7 +243,7 @@ static UINT read_stream_data( IStorage *stg, LPCWSTR stname, ...@@ -243,7 +243,7 @@ static UINT read_stream_data( IStorage *stg, LPCWSTR stname,
data = HeapAlloc( GetProcessHeap(), 0, sz ); data = HeapAlloc( GetProcessHeap(), 0, sz );
if( !data ) if( !data )
{ {
ERR("couldn't allocate memory r=%08lx!\n",r); WARN("couldn't allocate memory r=%08lx!\n",r);
ret = ERROR_NOT_ENOUGH_MEMORY; ret = ERROR_NOT_ENOUGH_MEMORY;
goto end; goto end;
} }
...@@ -252,7 +252,7 @@ static UINT read_stream_data( IStorage *stg, LPCWSTR stname, ...@@ -252,7 +252,7 @@ static UINT read_stream_data( IStorage *stg, LPCWSTR stname,
if( FAILED( r ) || ( count != sz ) ) if( FAILED( r ) || ( count != sz ) )
{ {
HeapFree( GetProcessHeap(), 0, data ); HeapFree( GetProcessHeap(), 0, data );
ERR("read stream failed r = %08lx!\n",r); WARN("read stream failed r = %08lx!\n",r);
goto end; goto end;
} }
...@@ -303,13 +303,13 @@ UINT read_raw_stream_data( MSIDATABASE *db, LPCWSTR stname, ...@@ -303,13 +303,13 @@ UINT read_raw_stream_data( MSIDATABASE *db, LPCWSTR stname,
r = IStream_Stat(stm, &stat, STATFLAG_NONAME ); r = IStream_Stat(stm, &stat, STATFLAG_NONAME );
if( FAILED( r ) ) if( FAILED( r ) )
{ {
ERR("open stream failed r = %08lx!\n",r); WARN("open stream failed r = %08lx!\n",r);
goto end; goto end;
} }
if( stat.cbSize.QuadPart >> 32 ) if( stat.cbSize.QuadPart >> 32 )
{ {
ERR("Too big!\n"); WARN("Too big!\n");
goto end; goto end;
} }
...@@ -317,7 +317,7 @@ UINT read_raw_stream_data( MSIDATABASE *db, LPCWSTR stname, ...@@ -317,7 +317,7 @@ UINT read_raw_stream_data( MSIDATABASE *db, LPCWSTR stname,
data = HeapAlloc( GetProcessHeap(), 0, sz ); data = HeapAlloc( GetProcessHeap(), 0, sz );
if( !data ) if( !data )
{ {
ERR("couldn't allocate memory r=%08lx!\n",r); WARN("couldn't allocate memory r=%08lx!\n",r);
ret = ERROR_NOT_ENOUGH_MEMORY; ret = ERROR_NOT_ENOUGH_MEMORY;
goto end; goto end;
} }
...@@ -326,7 +326,7 @@ UINT read_raw_stream_data( MSIDATABASE *db, LPCWSTR stname, ...@@ -326,7 +326,7 @@ UINT read_raw_stream_data( MSIDATABASE *db, LPCWSTR stname,
if( FAILED( r ) || ( count != sz ) ) if( FAILED( r ) || ( count != sz ) )
{ {
HeapFree( GetProcessHeap(), 0, data ); HeapFree( GetProcessHeap(), 0, data );
ERR("read stream failed r = %08lx!\n",r); WARN("read stream failed r = %08lx!\n",r);
goto end; goto end;
} }
...@@ -362,7 +362,7 @@ static UINT write_stream_data( IStorage *stg, LPCWSTR stname, ...@@ -362,7 +362,7 @@ static UINT write_stream_data( IStorage *stg, LPCWSTR stname,
HeapFree( GetProcessHeap(), 0, encname ); HeapFree( GetProcessHeap(), 0, encname );
if( FAILED( r ) ) if( FAILED( r ) )
{ {
ERR("open stream failed r = %08lx\n",r); WARN("open stream failed r = %08lx\n",r);
return ret; return ret;
} }
...@@ -370,7 +370,7 @@ static UINT write_stream_data( IStorage *stg, LPCWSTR stname, ...@@ -370,7 +370,7 @@ static UINT write_stream_data( IStorage *stg, LPCWSTR stname,
r = IStream_SetSize( stm, size ); r = IStream_SetSize( stm, size );
if( FAILED( r ) ) if( FAILED( r ) )
{ {
ERR("Failed to SetSize\n"); WARN("Failed to SetSize\n");
goto end; goto end;
} }
...@@ -378,14 +378,14 @@ static UINT write_stream_data( IStorage *stg, LPCWSTR stname, ...@@ -378,14 +378,14 @@ static UINT write_stream_data( IStorage *stg, LPCWSTR stname,
r = IStream_Seek( stm, pos, STREAM_SEEK_SET, NULL ); r = IStream_Seek( stm, pos, STREAM_SEEK_SET, NULL );
if( FAILED( r ) ) if( FAILED( r ) )
{ {
ERR("Failed to Seek\n"); WARN("Failed to Seek\n");
goto end; goto end;
} }
r = IStream_Write(stm, data, sz, &count ); r = IStream_Write(stm, data, sz, &count );
if( FAILED( r ) || ( count != sz ) ) if( FAILED( r ) || ( count != sz ) )
{ {
ERR("Failed to Write\n"); WARN("Failed to Write\n");
goto end; goto end;
} }
...@@ -436,7 +436,7 @@ UINT read_table_from_storage( MSIDATABASE *db, LPCWSTR name, MSITABLE **ptable) ...@@ -436,7 +436,7 @@ UINT read_table_from_storage( MSIDATABASE *db, LPCWSTR name, MSITABLE **ptable)
if( rawsize % row_size ) if( rawsize % row_size )
{ {
ERR("Table size is invalid %d/%d\n", rawsize, row_size ); WARN("Table size is invalid %d/%d\n", rawsize, row_size );
return ERROR_FUNCTION_FAILED; return ERROR_FUNCTION_FAILED;
} }
...@@ -771,13 +771,13 @@ UINT save_string_table( MSIDATABASE *db ) ...@@ -771,13 +771,13 @@ UINT save_string_table( MSIDATABASE *db )
pool = HeapAlloc( GetProcessHeap(), 0, poolsize ); pool = HeapAlloc( GetProcessHeap(), 0, poolsize );
if( ! pool ) if( ! pool )
{ {
ERR("Failed to alloc pool %d bytes\n", poolsize ); WARN("Failed to alloc pool %d bytes\n", poolsize );
goto err; goto err;
} }
data = HeapAlloc( GetProcessHeap(), 0, datasize ); data = HeapAlloc( GetProcessHeap(), 0, datasize );
if( ! data ) if( ! data )
{ {
ERR("Failed to alloc data %d bytes\n", poolsize ); WARN("Failed to alloc data %d bytes\n", poolsize );
goto err; goto err;
} }
...@@ -921,7 +921,7 @@ static UINT get_tablecolumns( MSIDATABASE *db, ...@@ -921,7 +921,7 @@ static UINT get_tablecolumns( MSIDATABASE *db,
r = get_table( db, szColumns, &table); r = get_table( db, szColumns, &table);
if( r != ERROR_SUCCESS ) if( r != ERROR_SUCCESS )
{ {
ERR("table %s not available\n", debugstr_w(szColumns)); WARN("table %s not available\n", debugstr_w(szColumns));
return r; return r;
} }
...@@ -930,7 +930,7 @@ static UINT get_tablecolumns( MSIDATABASE *db, ...@@ -930,7 +930,7 @@ static UINT get_tablecolumns( MSIDATABASE *db,
if( r != ERROR_SUCCESS ) if( r != ERROR_SUCCESS )
{ {
release_table( db, table ); release_table( db, table );
ERR("Couldn't find id for %s\n", debugstr_w(szTableName)); WARN("Couldn't find id for %s\n", debugstr_w(szTableName));
return r; return r;
} }
...@@ -999,7 +999,7 @@ BOOL TABLE_Exists( MSIDATABASE *db, LPWSTR name ) ...@@ -999,7 +999,7 @@ BOOL TABLE_Exists( MSIDATABASE *db, LPWSTR name )
r = get_table( db, szTables, &table); r = get_table( db, szTables, &table);
if( r != ERROR_SUCCESS ) if( r != ERROR_SUCCESS )
{ {
ERR("table %s not available\n", debugstr_w(szTables)); TRACE("table %s not available\n", debugstr_w(szTables));
return FALSE; return FALSE;
} }
...@@ -1014,7 +1014,7 @@ BOOL TABLE_Exists( MSIDATABASE *db, LPWSTR name ) ...@@ -1014,7 +1014,7 @@ BOOL TABLE_Exists( MSIDATABASE *db, LPWSTR name )
if (i!=count) if (i!=count)
return TRUE; return TRUE;
ERR("Searched %d tables, but %d was not found\n", count, table_id ); TRACE("Searched %d tables, but %d was not found\n", count, table_id );
return FALSE; return FALSE;
} }
...@@ -1395,7 +1395,7 @@ UINT MSI_CommitTables( MSIDATABASE *db ) ...@@ -1395,7 +1395,7 @@ UINT MSI_CommitTables( MSIDATABASE *db )
r = save_string_table( db ); r = save_string_table( db );
if( r != ERROR_SUCCESS ) if( r != ERROR_SUCCESS )
{ {
ERR("failed to save string table r=%08x\n",r); WARN("failed to save string table r=%08x\n",r);
return r; return r;
} }
...@@ -1404,7 +1404,7 @@ UINT MSI_CommitTables( MSIDATABASE *db ) ...@@ -1404,7 +1404,7 @@ UINT MSI_CommitTables( MSIDATABASE *db )
r = save_table( db, table ); r = save_table( db, table );
if( r != ERROR_SUCCESS ) if( r != ERROR_SUCCESS )
{ {
ERR("failed to save table %s (r=%08x)\n", WARN("failed to save table %s (r=%08x)\n",
debugstr_w(table->name), r); debugstr_w(table->name), r);
return r; return r;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment