| 76 |
|
|
| 77 |
if (mbstowcs(wcs, input_str, 1) == (size_t)-1) |
if (mbstowcs(wcs, input_str, 1) == (size_t)-1) |
| 78 |
{ |
{ |
| 79 |
#ifdef _DEBUG |
log_debug("mbstowcs(%s) error\n", input_str); |
|
log_error("mbstowcs(%s) error\n", input_str); |
|
|
#endif |
|
| 80 |
wc_len = (UTF8_fixed_width ? 2 : 1); // Fallback |
wc_len = (UTF8_fixed_width ? 2 : 1); // Fallback |
| 81 |
} |
} |
| 82 |
else |
else |
| 140 |
|
|
| 141 |
if (mbstowcs(wcs, input_str, 1) == (size_t)-1) |
if (mbstowcs(wcs, input_str, 1) == (size_t)-1) |
| 142 |
{ |
{ |
| 143 |
#ifdef _DEBUG |
log_debug("mbstowcs(%s) error\n", input_str); |
|
log_error("mbstowcs(%s) error\n", input_str); |
|
|
#endif |
|
| 144 |
wc_len = (UTF8_fixed_width ? 2 : 1); // Fallback |
wc_len = (UTF8_fixed_width ? 2 : 1); // Fallback |
| 145 |
} |
} |
| 146 |
else |
else |
| 199 |
// Exceed max_line_cnt |
// Exceed max_line_cnt |
| 200 |
if (line_cnt + 1 >= line_offsets_count) |
if (line_cnt + 1 >= line_offsets_count) |
| 201 |
{ |
{ |
| 202 |
#ifdef _DEBUG |
log_debug("Line count %d reaches limit %d\n", line_cnt + 1, line_offsets_count); |
|
log_error("Line count %d reaches limit %d\n", line_cnt + 1, line_offsets_count); |
|
|
#endif |
|
| 203 |
return line_cnt; |
return line_cnt; |
| 204 |
} |
} |
| 205 |
|
|