From: Ari Johnson Date: Wed, 13 Jan 2016 16:02:18 +0000 (-0500) Subject: Bugfix: @prog could not use attribute trees from parent objects X-Git-Url: https://git.theari.com/?a=commitdiff_plain;h=7c17516ca81341ac437f8c3e26f0c8d5767a846b;p=cobramush.git Bugfix: @prog could not use attribute trees from parent objects --- diff --git a/game/txt/changes/0.73p4 b/game/txt/changes/0.73p4 index 2cff2ac..b4d1714 100644 --- a/game/txt/changes/0.73p4 +++ b/game/txt/changes/0.73p4 @@ -13,3 +13,4 @@ CobraMUSH Version 0.73p4 Fixes: * Compiler warning when RPMODE_SYS enabled [AEJ] * Recently introduced bug in channel connect/disconnect broadcasts [AEJ] + * @prog could not use attribute trees from parent objects [AEJ] diff --git a/src/prog.c b/src/prog.c index 5c350ef..8f185f6 100644 --- a/src/prog.c +++ b/src/prog.c @@ -146,7 +146,7 @@ COMMAND(cmd_prog) notify(player, "No such attribute."); notify(player, s); return; - } else if (!Can_Write_Attr(player, thing, patr)) { + } else if (!Can_Read_Attr(player, thing, patr)) { notify(player, "Permission denied."); return; } @@ -257,7 +257,7 @@ FUNCTION(fun_prog) else if ((patr = atr_get(thing, upcasestr(args[2]))) == NULL) { safe_str("#-1 NO SUCH ATTRIB", buff, bp); return; - } else if (!Can_Write_Attr(executor, thing, patr)) { + } else if (!Can_Read_Attr(executor, thing, patr)) { safe_str("#-1 PERMISSION DENIED", buff, bp); return; }