diff -up rpm-4.8.0/lib/psm.c.strict-script rpm-4.8.0/lib/psm.c --- rpm-4.8.0/lib/psm.c.strict-script 2013-08-05 11:09:40.290136043 +0300 +++ rpm-4.8.0/lib/psm.c 2013-08-05 11:12:18.465137945 +0300 @@ -517,7 +517,9 @@ static rpmRC runLuaScript(rpmpsm psm, He if (rc != RPMRC_OK) { if ((stag != RPMTAG_PREIN && stag != RPMTAG_PREUN && stag != RPMTAG_VERIFYSCRIPT && stag != RPMTAG_PRETRANS)) { - warn_only = 1; + if (!rpmExpandNumeric("%{?_strict_script_errors}")) { + warn_only = 1; + } } } umask(oldmask); @@ -774,7 +776,9 @@ static rpmRC runScript(rpmpsm psm, Heade } else { /* filter out "regular" error exits from non-pre scriptlets */ if ((stag != RPMTAG_PREIN && stag != RPMTAG_PREUN && stag != RPMTAG_VERIFYSCRIPT && stag != RPMTAG_PRETRANS)) { - warn_only = 1; + if (!rpmExpandNumeric("%{?_strict_script_errors}")) { + warn_only = 1; + } } rpmlog(warn_only ? RPMLOG_WARNING : RPMLOG_ERR, _("%s scriptlet failed, exit status %d\n"),