Commit 82e20b72 authored by 's avatar

Fixed up eval support

parent d3cb4bb0
...@@ -11,8 +11,8 @@ ...@@ -11,8 +11,8 @@
__doc__='''Application support __doc__='''Application support
$Id: Application.py,v 1.42 1998/01/28 23:39:02 brian Exp $''' $Id: Application.py,v 1.43 1998/01/29 20:52:20 brian Exp $'''
__version__='$Revision: 1.42 $'[11:-2] __version__='$Revision: 1.43 $'[11:-2]
import Globals,Folder,os,regex,sys import Globals,Folder,os,regex,sys
...@@ -205,9 +205,8 @@ def install_products(): ...@@ -205,9 +205,8 @@ def install_products():
product=getattr(__import__("Products.%s" % product_name), product_name) product=getattr(__import__("Products.%s" % product_name), product_name)
if product_name not in ['OFSP','MailHost']: if not lic_check(product_name):
if not lic_check(product_name): continue
continue
for meta_type in pgetattr(product, 'meta_types', ()): for meta_type in pgetattr(product, 'meta_types', ()):
if product_name=='OFSP': meta_types.insert(0,meta_type) if product_name=='OFSP': meta_types.insert(0,meta_type)
...@@ -311,9 +310,12 @@ def lic_check(product_name): ...@@ -311,9 +310,12 @@ def lic_check(product_name):
p=rfind(s,'.') p=rfind(s,'.')
m='Products.%s.%s' % (product_name, s[:p]) m='Products.%s.%s' % (product_name, s[:p])
c=s[p+1:] c=s[p+1:]
__import__(m) try: __import__(m)
except:
m=s[:p]
__import__(m)
setattr(sys.modules[m], c, Expired) setattr(sys.modules[m], c, Expired)
return 0 return 0
...@@ -343,6 +345,9 @@ class Misc_: ...@@ -343,6 +345,9 @@ class Misc_:
############################################################################## ##############################################################################
# #
# $Log: Application.py,v $ # $Log: Application.py,v $
# Revision 1.43 1998/01/29 20:52:20 brian
# Fixed up eval support
#
# Revision 1.42 1998/01/28 23:39:02 brian # Revision 1.42 1998/01/28 23:39:02 brian
# Added licensing logic # Added licensing logic
# #
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment