Skip to content

Commit

Permalink
Fix book crash with malicious form data
Browse files Browse the repository at this point in the history
  • Loading branch information
appgurueu committed Dec 21, 2024
1 parent f4f3659 commit 9bcf2d4
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions mods/default/craftitems.lua
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,8 @@ minetest.register_on_player_receive_fields(function(player, formname, fields)
string = formspec_string(lpp, data.page, lines, string)
contents = formspec_read(player_name, title, string,
text, data.page, data.page_max)
else
return -- malicious data
end
tab_number = tab
local formspec = formspec_size .. formspec_core(tab) .. contents
Expand Down

0 comments on commit 9bcf2d4

Please sign in to comment.