Suresoft-GLaDOS/bugscpp

libchewing bugs 1 and 2 are identical

Opened this issue · 1 comments

Just like the reported libucl bug 3 and 5, libchewing project also contains redundant bugs.

index 2473c3b..d2cf9ee 100644
--- a/src/chewingio.c
+++ b/src/chewingio.c
@@ -694,7 +694,8 @@ CHEWING_API void chewing_set_ChiEngMode(ChewingContext *ctx, int mode)
if (mode == CHINESE_MODE || mode == SYMBOL_MODE) {
// remove all data inside buffer as switching mode.
- chewing_clean_bopomofo_buf(ctx);
+ BopomofoRemoveAll(&(ctx->data->bopomofoData));
+ MakeOutputWithRtn(ctx->output, ctx->data, KEYSTROKE_ABSORB);
ctx->data->bChiSym = mode;
}
}
--

index 0830299..6f10129 100644
--- a/src/chewingio.c
+++ b/src/chewingio.c
@@ -694,7 +694,8 @@ CHEWING_API void chewing_set_ChiEngMode(ChewingContext *ctx, int mode)
if (mode == CHINESE_MODE || mode == SYMBOL_MODE) {
// remove all data inside buffer as switching mode.
- chewing_clean_bopomofo_buf(ctx);
+ BopomofoRemoveAll(&(ctx->data->bopomofoData));
+ MakeOutputWithRtn(ctx->output, ctx->data, KEYSTROKE_ABSORB);
ctx->data->bChiSym = mode;
}
}
--

Thanks for your reporting!
We will include this issue in our future improvements.
(with libucl bugs - issue #159)