Don't abort if embryo_cc's return code is 1.
authorTilman Sauerbeck <tilman@code-monkey.de>
Thu, 28 Apr 2005 21:08:11 +0000 (21:08 +0000)
committerTilman Sauerbeck <tilman@code-monkey.de>
Thu, 28 Apr 2005 21:08:11 +0000 (21:08 +0000)
1 means 'succeeded, but with warnings'.

ChangeLog
lib/redact/app.rb

index 0acb35147c2848dcb8b193cc1f8b039cd7c0688a..32ff1d1f90dc3f446f89238b8952e99f2f1e2c3c 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,7 +1,11 @@
 --
 --
-$Id: ChangeLog 38 2005-04-25 17:47:15Z tilman $
+$Id: ChangeLog 39 2005-04-28 21:08:11Z tilman $
 ++
 
 ++
 
+2005-04-28 Tilman Sauerbeck (tilman at code-monkey de)
+        * lib/redact/app.rb: Don't abort if embryo_cc's return code is 1
+          (which means 'succeeded, but with warnings')
+
 2005-04-25 Tilman Sauerbeck (tilman at code-monkey de)
         * Rakefile: Don't include one FileList in another
 
 2005-04-25 Tilman Sauerbeck (tilman at code-monkey de)
         * Rakefile: Don't include one FileList in another
 
index 351897e2ef4c7e693535af593a5d7192d3d438c8..dc9ef9b52b4d52bb8fb8697e0a0cd1f26c452eeb 100644 (file)
@@ -1,5 +1,5 @@
 #--
 #--
-# $Id: app.rb 30 2005-04-23 15:25:21Z tilman $
+# $Id: app.rb 39 2005-04-28 21:08:11Z tilman $
 #
 # Copyright (c) 2005 Tilman Sauerbeck (tilman at code-monkey de)
 #
 #
 # Copyright (c) 2005 Tilman Sauerbeck (tilman at code-monkey de)
 #
@@ -135,7 +135,8 @@ module Redact
                                                c = "embryo_cc " +
                                                    "-i #{incl}/include " +
                                                    "-o #{tf_out.path} #{tf_in.path}"
                                                c = "embryo_cc " +
                                                    "-i #{incl}/include " +
                                                    "-o #{tf_out.path} #{tf_in.path}"
-                                               unless system(c)
+                                               system(c)
+                                               unless (0..1).include?($?.exitstatus)
                                                        raise("Cannot compile Embryo code")
                                                end
 
                                                        raise("Cannot compile Embryo code")
                                                end