comparison mcabber/src/screen.c @ 884:9e6d9f0cf9eb

scr_LogPrint(): Add a warning for UTF-8 -> locale conversion failures
author Mikael Berthe <mikael@lilotux.net>
date Sat, 27 May 2006 19:46:20 +0200
parents ea983a945eba
children 578d2034e971
comparison
equal deleted inserted replaced
883:0aa9015f06df 884:9e6d9f0cf9eb
362 if (!(flag & LPRINT_NOTUTF8)) 362 if (!(flag & LPRINT_NOTUTF8))
363 buffer_locale = from_utf8(buffer); 363 buffer_locale = from_utf8(buffer);
364 else 364 else
365 buffer_locale = buffer; 365 buffer_locale = buffer;
366 366
367 if (!buffer_locale) {
368 wprintw(logWnd,
369 "\n%s*Error: cannot convert string to locale.", strtimestamp);
370 update_panels();
371 doupdate();
372 g_free(buffer);
373 return;
374 }
375
367 // For the special status buffer, we need utf-8, but without the timestamp 376 // For the special status buffer, we need utf-8, but without the timestamp
368 if (flag & LPRINT_NOTUTF8) 377 if (flag & LPRINT_NOTUTF8)
369 buf_specialwindow = to_utf8(btext); 378 buf_specialwindow = to_utf8(btext);
370 else 379 else
371 buf_specialwindow = btext; 380 buf_specialwindow = btext;