1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-10-19 19:59:43 +00:00

Two fixes:

- Properly import PIL module;
- don't try to do os.chdir() with empty argument.
This commit is contained in:
Maxim Sobolev 2001-01-18 19:28:48 +00:00
parent f12751a5d7
commit a318676894
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=37306
2 changed files with 25 additions and 0 deletions

View File

@ -7,6 +7,7 @@
PORTNAME= threeDS
PORTVERSION= 0.2
PORTREVISION= 1
CATEGORIES= graphics python
MASTER_SITES= http://www.demonseed.net/~jp/code/threeDS/

View File

@ -0,0 +1,24 @@
$FreeBSD$
--- threeDS.py 2001/01/18 19:26:14 1.1
+++ threeDS.py 2001/01/18 19:26:19
@@ -82,7 +82,7 @@
self.imgfile = readStr(f)
# print "texture: " + self.imgfile
try:
- from Imaging import Image
+ from PIL import Image
except:
print 'Can\'t load texture without PIL!!'
continue
@@ -370,7 +370,8 @@
def __init__(self, filename):
(path, filename) = os.path.split(filename)
- os.chdir(path)
+ if path != '':
+ os.chdir(path)
f = open(filename, "rb")
if f is None:
print "error loading " + str(filename) + "."