Lines Matching refs:identd

384 	mbfl_encoding_detector *identd;  in mbfl_encoding_detector_new()  local
394 identd = (mbfl_encoding_detector*)mbfl_malloc(sizeof(mbfl_encoding_detector)); in mbfl_encoding_detector_new()
395 if (identd == NULL) { in mbfl_encoding_detector_new()
398identd->filter_list = (mbfl_identify_filter **)mbfl_calloc(elistsz, sizeof(mbfl_identify_filter *)… in mbfl_encoding_detector_new()
399 if (identd->filter_list == NULL) { in mbfl_encoding_detector_new()
400 mbfl_free(identd); in mbfl_encoding_detector_new()
410 identd->filter_list[num] = filter; in mbfl_encoding_detector_new()
415 identd->filter_list_size = num; in mbfl_encoding_detector_new()
418 identd->strict = strict; in mbfl_encoding_detector_new()
420 return identd; in mbfl_encoding_detector_new()
426 mbfl_encoding_detector *identd; in mbfl_encoding_detector_new2() local
436 identd = (mbfl_encoding_detector*)mbfl_malloc(sizeof(mbfl_encoding_detector)); in mbfl_encoding_detector_new2()
437 if (identd == NULL) { in mbfl_encoding_detector_new2()
440identd->filter_list = (mbfl_identify_filter **)mbfl_calloc(elistsz, sizeof(mbfl_identify_filter *)… in mbfl_encoding_detector_new2()
441 if (identd->filter_list == NULL) { in mbfl_encoding_detector_new2()
442 mbfl_free(identd); in mbfl_encoding_detector_new2()
452 identd->filter_list[num] = filter; in mbfl_encoding_detector_new2()
457 identd->filter_list_size = num; in mbfl_encoding_detector_new2()
460 identd->strict = strict; in mbfl_encoding_detector_new2()
462 return identd; in mbfl_encoding_detector_new2()
467 mbfl_encoding_detector_delete(mbfl_encoding_detector *identd) in mbfl_encoding_detector_delete() argument
471 if (identd != NULL) { in mbfl_encoding_detector_delete()
472 if (identd->filter_list != NULL) { in mbfl_encoding_detector_delete()
473 i = identd->filter_list_size; in mbfl_encoding_detector_delete()
476 mbfl_identify_filter_delete(identd->filter_list[i]); in mbfl_encoding_detector_delete()
478 mbfl_free((void *)identd->filter_list); in mbfl_encoding_detector_delete()
480 mbfl_free((void *)identd); in mbfl_encoding_detector_delete()
485 mbfl_encoding_detector_feed(mbfl_encoding_detector *identd, mbfl_string *string) in mbfl_encoding_detector_feed() argument
493 if (identd != NULL && string != NULL && string->val != NULL) { in mbfl_encoding_detector_feed()
494 num = identd->filter_list_size; in mbfl_encoding_detector_feed()
500 filter = identd->filter_list[i]; in mbfl_encoding_detector_feed()
520 const mbfl_encoding *mbfl_encoding_detector_judge2(mbfl_encoding_detector *identd) in mbfl_encoding_detector_judge2() argument
527 if (identd != NULL) { in mbfl_encoding_detector_judge2()
528 n = identd->filter_list_size - 1; in mbfl_encoding_detector_judge2()
530 filter = identd->filter_list[n]; in mbfl_encoding_detector_judge2()
532 if (!identd->strict || !filter->status) { in mbfl_encoding_detector_judge2()
541 n = identd->filter_list_size - 1; in mbfl_encoding_detector_judge2()
543 filter = identd->filter_list[n]; in mbfl_encoding_detector_judge2()
555 enum mbfl_no_encoding mbfl_encoding_detector_judge(mbfl_encoding_detector *identd) in mbfl_encoding_detector_judge() argument
557 const mbfl_encoding *encoding = mbfl_encoding_detector_judge2(identd); in mbfl_encoding_detector_judge()