diff options
author | Torbjörn Andersson | 2004-05-05 13:05:45 +0000 |
---|---|---|
committer | Torbjörn Andersson | 2004-05-05 13:05:45 +0000 |
commit | 148872d1fd622092cb7975d414bb6f161d0801ef (patch) | |
tree | 336a5580e55e56c85862b2a0a3e0b5fe3ddb5262 /saga/palanim.cpp | |
parent | 4102a3b13f1455ddfd7e8b17e4f8f1bd1e14f0c2 (diff) | |
download | scummvm-rg350-148872d1fd622092cb7975d414bb6f161d0801ef.tar.gz scummvm-rg350-148872d1fd622092cb7975d414bb6f161d0801ef.tar.bz2 scummvm-rg350-148872d1fd622092cb7975d414bb6f161d0801ef.zip |
Replaced R_printf() with debug() and warning(). There are still a couple of
standard printf()s left, though.
svn-id: r13791
Diffstat (limited to 'saga/palanim.cpp')
-rw-r--r-- | saga/palanim.cpp | 26 |
1 files changed, 9 insertions, 17 deletions
diff --git a/saga/palanim.cpp b/saga/palanim.cpp index d0d3565952..6936e913c8 100644 --- a/saga/palanim.cpp +++ b/saga/palanim.cpp @@ -56,11 +56,11 @@ int PALANIM_Load(const byte *resdata, size_t resdata_len) { PAnimData.entry_count = readS->readUint16LE(); - R_printf(R_STDOUT, "PALANIM_Load(): Loading %d PALANIM entries.\n", PAnimData.entry_count); + debug(0, "PALANIM_Load(): Loading %d PALANIM entries.", PAnimData.entry_count); test_p = calloc(PAnimData.entry_count, sizeof(PALANIM_ENTRY)); if (test_p == NULL) { - R_printf(R_STDERR, "PALANIM_Load(): Allocation failure.\n"); + warning("PALANIM_Load(): Allocation failure"); return R_MEM; } @@ -77,25 +77,21 @@ int PALANIM_Load(const byte *resdata, size_t resdata_len) { PAnimData.entries[i].pal_count = pal_count; PAnimData.entries[i].color_count = color_count; -#if 0 - R_printf(R_STDOUT, "PALANIM_Load(): Entry %d: Loading %d palette indices.\n", i, pal_count); -#endif + debug(2, "PALANIM_Load(): Entry %d: Loading %d palette indices.\n", i, pal_count); test_p = calloc(1, sizeof(char) * pal_count); if (test_p == NULL) { - R_printf(R_STDERR, "PALANIM_Load(): Allocation failure.\n"); + warning("PALANIM_Load(): Allocation failure"); return R_MEM; } PAnimData.entries[i].pal_index = (byte *)test_p; -#if 0 - R_printf(R_STDOUT, "PALANIM_Load(): Entry %d: Loading %d SAGA_COLOR structures.\n", i, color_count); -#endif + debug(2, "PALANIM_Load(): Entry %d: Loading %d SAGA_COLOR structures.", i, color_count); test_p = calloc(1, sizeof(R_COLOR) * color_count); if (test_p == NULL) { - R_printf(R_STDERR, "PALANIM_Load(): Allocation failure.\n"); + warning("PALANIM_Load(): Allocation failure"); return R_MEM; } @@ -191,17 +187,13 @@ int PALANIM_Free() { } for (i = 0; i < PAnimData.entry_count; i++) { -#if 0 - R_printf(R_STDOUT, "PALANIM_Free(): Entry %d: Freeing colors.\n", i); -#endif + debug(2, "PALANIM_Free(): Entry %d: Freeing colors.", i); free(PAnimData.entries[i].colors); -#if 0 - R_printf(R_STDOUT, "PALANIM_Free(): Entry %d: Freeing indices.\n", i); -#endif + debug(2, "PALANIM_Free(): Entry %d: Freeing indices.", i); free(PAnimData.entries[i].pal_index); } - R_printf(R_STDOUT, "PALANIM_Free(): Freeing entries.\n"); + debug(0, "PALANIM_Free(): Freeing entries."); free(PAnimData.entries); |