From a38c3578c7f18405048d97011808baf39e3ecf69 Mon Sep 17 00:00:00 2001
From: Martin Nilsson <mani@lysator.liu.se>
Date: Wed, 16 Oct 2002 12:11:14 +0200
Subject: [PATCH] Propagate compilation errors from crypto modules.

Rev: lib/modules/Crypto.pmod:1.11
---
 lib/modules/Crypto.pmod | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/lib/modules/Crypto.pmod b/lib/modules/Crypto.pmod
index 613c518df1..365478cb80 100644
--- a/lib/modules/Crypto.pmod
+++ b/lib/modules/Crypto.pmod
@@ -8,11 +8,13 @@ private mixed crypto_module;
 
 static mixed `[](string name)
 {
-    catch {
+    mixed err = catch {
       return (crypto_module[name]
 	      || ((program) combine_path( __FILE__, "..", "Crypto" , name + ".pike"))
 	      || ((object) combine_path( __FILE__, "..","Crypto", name + ".pmod")));
     };
+    if( file_stat("Crypto/"+name) || file_stat("Crypto/"+name+".pmod") )
+      throw(err);
     return UNDEFINED;
 }
 
-- 
GitLab