decrpm_asu_cb: correct follow

pull/2224/head
nick black 3 years ago committed by nick black
parent 1442b35fb5
commit 49365e2d22

@ -320,8 +320,9 @@ amata_next_numeric(automaton* amata, const char* prefix, char follow){
ret += addend;
++amata->matchstart;
}
if(*amata->matchstart++ != follow){
logerror("didn't see follow (%c)\n", follow);
char candidate = *amata->matchstart++;
if(candidate != follow){
logerror("didn't see follow (%c vs %c)\n", candidate, follow);
return 0;
}
return ret;
@ -659,7 +660,7 @@ kittygraph_cb(inputctx* ictx){
static int
decrpm_asu_cb(inputctx* ictx){
unsigned ps = amata_next_numeric(&ictx->amata, "\x1b[?2026;", 'y');
unsigned ps = amata_next_numeric(&ictx->amata, "\x1b[?2026;", '$');
loginfo("received decrpm 2026 %u\n", ps);
if(ps == 2){
if(ictx->initdata){

Loading…
Cancel
Save