diff -r 28ccaba883f4 -r 403e7f6ed6c5 glib/tests/nullify-ptr.c --- a/glib/tests/nullify-ptr.c Wed Oct 13 19:39:18 2010 +0530 +++ b/glib/tests/nullify-ptr.c Thu Oct 14 14:15:50 2010 +0530 @@ -16,37 +16,38 @@ #undef G_DISABLE_ASSERT #undef G_LOG_DOMAIN +#include #include -#define LOG_FILE "c:\\logs\\nullify_ptr_log.txt" -#include "std_log_result.h" -#define LOG_FILENAME_LINE __FILE__, __LINE__ - -void create_xml(int result) -{ - if(result) - assert_failed = 1; - - testResultXml("nullify_ptr_log"); - close_log_file(); -} +#include +#ifdef __SYMBIAN32__ +#include "mrt2_glib2_test.h" +#endif /*__SYMBIAN32__*/ int main (int argc, char *argv[]) { char *ptr; - g_nullify_pointer((gpointer)&ptr); + #ifdef __SYMBIAN32__ + g_log_set_handler (NULL, G_LOG_FLAG_FATAL| G_LOG_FLAG_RECURSION | G_LOG_LEVEL_CRITICAL | G_LOG_LEVEL_WARNING | G_LOG_LEVEL_MESSAGE | G_LOG_LEVEL_INFO | G_LOG_LEVEL_DEBUG, &mrtLogHandler, NULL); + g_set_print_handler(mrtPrintHandler); + #endif /*__SYMBIAN32__*/ + + g_print("Test nullify-ptr Start"); + g_nullify_pointer((gpointer)&ptr); if(ptr != NULL) { - std_log(LOG_FILENAME_LINE,"ptr is not NULL"); + g_print("ptr is not NULL"); assert_failed = 1; } if(assert_failed) - std_log(LOG_FILENAME_LINE,"Test Fail"); + g_print("Test nullify-ptr Fail"); else - std_log(LOG_FILENAME_LINE,"Test Successful"); + g_print("Test nullify-ptr Successful"); - create_xml(0); + #if __SYMBIAN32__ + testResultXml("nullify-ptr"); + #endif /* EMULATOR */ return 0; }