Ejemplo n.º 1
0
/* create scws engine */
scws_t scws_new() {
    scws_t s;
    s = (scws_t) malloc(sizeof (scws_st));
    if (s == NULL)
        return s;
    memset(s, 0, sizeof (scws_st));
    s->mblen = charset_table_get(NULL);
    s->off = s->len = 0;
    s->wend = -1;

    return s;
}
Ejemplo n.º 2
0
Archivo: scws.c Proyecto: 9466/scws
void scws_set_charset(scws_t s, const char *cs)
{
	s->mblen = charset_table_get(cs);
}