Skip to content

Commit

Permalink
Fix flipped sense in TerminalDispatch::CursorPosition (#4113)
Browse files Browse the repository at this point in the history
Fixes #4107.
  • Loading branch information
DHowett authored Jan 6, 2020
1 parent a60ed52 commit 4882917
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/cascadia/TerminalCore/TerminalDispatch.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,11 @@ try
SHORT x{ 0 };
SHORT y{ 0 };

RETURN_BOOL_IF_FALSE(FAILED(SizeTToShort(column, &x)) ||
FAILED(SizeTToShort(line, &y)));
RETURN_BOOL_IF_FALSE(SUCCEEDED(SizeTToShort(column, &x)) &&
SUCCEEDED(SizeTToShort(line, &y)));

RETURN_BOOL_IF_FALSE(FAILED(ShortSub(x, 1, &x)) ||
FAILED(ShortSub(y, 1, &y)));
RETURN_BOOL_IF_FALSE(SUCCEEDED(ShortSub(x, 1, &x)) &&
SUCCEEDED(ShortSub(y, 1, &y)));

return _terminalApi.SetCursorPosition(x, y);
}
Expand Down

0 comments on commit 4882917

Please sign in to comment.