From dfb960139cb30cf16e333d9237e64b576afc6771 Mon Sep 17 00:00:00 2001 From: Erthilo Date: Thu, 10 May 2012 01:56:37 +0100 Subject: [PATCH] TG: Sanitize added to agent cards and ID computer. Revision: r3556 Author: johnsonmt88 --- code/game/machinery/computer/card.dm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/code/game/machinery/computer/card.dm b/code/game/machinery/computer/card.dm index 8914d5b6ff4..9e79a702fc4 100644 --- a/code/game/machinery/computer/card.dm +++ b/code/game/machinery/computer/card.dm @@ -245,7 +245,9 @@ if (authenticated) var/t1 = href_list["assign_target"] if(t1 == "Custom") - t1 = input("Enter a custom job assignment.","Assignment") + var/temp_t = copytext(sanitize(input("Enter a custom job assignment.","Assignment")),1,MAX_MESSAGE_LEN) + if(temp_t) + t1 = temp_t else modify.access = ( istype(src,/obj/machinery/computer/card/centcom) ? get_centcom_access(t1) : get_access(t1) ) if (modify)