mirror of
https://github.com/ilyakooo0/urbit.git
synced 2024-12-25 16:05:27 +03:00
vere: suppress null writes in term.c
This commit is contained in:
parent
42e8158be9
commit
412bae2cd4
@ -298,8 +298,10 @@ static void
|
|||||||
_term_it_dump_buf(u3_utty* uty_u,
|
_term_it_dump_buf(u3_utty* uty_u,
|
||||||
uv_buf_t* buf_u)
|
uv_buf_t* buf_u)
|
||||||
{
|
{
|
||||||
|
if ( buf_u->len ) {
|
||||||
_term_it_write(uty_u, buf_u, 0);
|
_term_it_write(uty_u, buf_u, 0);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/* _term_it_dump(): write static vector.
|
/* _term_it_dump(): write static vector.
|
||||||
*/
|
*/
|
||||||
@ -317,11 +319,16 @@ _term_it_dump(u3_utty* uty_u,
|
|||||||
static void
|
static void
|
||||||
_term_it_send(u3_utty* uty_u,
|
_term_it_send(u3_utty* uty_u,
|
||||||
c3_w len_w,
|
c3_w len_w,
|
||||||
const c3_y* hun_y)
|
c3_y* hun_y)
|
||||||
{
|
{
|
||||||
|
if ( len_w ) {
|
||||||
uv_buf_t buf_u = uv_buf_init((c3_c*)hun_y, len_w);
|
uv_buf_t buf_u = uv_buf_init((c3_c*)hun_y, len_w);
|
||||||
_term_it_write(uty_u, &buf_u, (void*)hun_y);
|
_term_it_write(uty_u, &buf_u, (void*)hun_y);
|
||||||
}
|
}
|
||||||
|
else {
|
||||||
|
c3_free(hun_y);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/* _term_it_send_csi(): send csi escape sequence
|
/* _term_it_send_csi(): send csi escape sequence
|
||||||
*/
|
*/
|
||||||
|
Loading…
Reference in New Issue
Block a user