Skip to content

Commit

Permalink
Fix buffer overflow in rofi -e after reading from stdin (#2082)
Browse files Browse the repository at this point in the history
  • Loading branch information
faulesocke authored Jan 16, 2025
1 parent 329a5dd commit 4cdca24
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions source/rofi.c
Original file line number Diff line number Diff line change
Expand Up @@ -823,6 +823,8 @@ static gboolean startup(G_GNUC_UNUSED gpointer data) {
msg = realloc(msg, length * sizeof(char));
}

msg[index] = 0;

if (!rofi_view_error_dialog(msg, markup)) {
g_main_loop_quit(main_loop);
}
Expand Down

0 comments on commit 4cdca24

Please sign in to comment.