ant_on_air: Exec task makes Ant fail if failonerror is true and the NativeProcessExitEvent exitCode is not 0
diff --git a/flex-installer/ant_on_air/src/org/apache/flex/ant/tags/Exec.as b/flex-installer/ant_on_air/src/org/apache/flex/ant/tags/Exec.as
index bc503a6..e5eced7 100644
--- a/flex-installer/ant_on_air/src/org/apache/flex/ant/tags/Exec.as
+++ b/flex-installer/ant_on_air/src/org/apache/flex/ant/tags/Exec.as
@@ -126,11 +126,23 @@
         {
             return getAttributeValue("@outputproperty");
         }
+
+        override public function get failonerror():Boolean
+        {
+            var val:String = getNullOrAttributeValue("@failonerror");
+            //if omitted, defaults to false
+            return val == null ? false : val == "true";
+        }
         
         private var process:NativeProcess;
         
         private function exitHandler(event:NativeProcessExitEvent):void
         {
+            if(event.exitCode !== 0 && failonerror)
+            {
+                ant.project.failureMessage = "Exec task failed: " + fileName;
+                ant.project.status = false;
+            }
             dispatchEvent(new Event(Event.COMPLETE));
         }