Changeset 2008

Show
Ignore:
Timestamp:
01/07/05 00:24:21 (20 years ago)
Author:
jalet
Message:

Regain priviledge the time to open the job's data file when printing in
raw mode with CUPS.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • pykota/trunk/pykota/tool.py

    r2006 r2008  
    2222# 
    2323# $Log$ 
     24# Revision 1.148  2005/01/06 23:24:21  jalet 
     25# Regain priviledge the time to open the job's data file when printing in 
     26# raw mode with CUPS. 
     27# 
    2428# Revision 1.147  2005/01/06 22:52:53  jalet 
    2529# Implemented the dropping of priviledges. Beware, beware... 
     
    690694                self.printInfo(_("Impossible to regain priviledges : %s") % msg, "warn") 
    691695            else :     
    692                 self.logdebug(_("Regained priviledges.")) 
     696                self.logdebug(_("Regained priviledges. Now running as root.")) 
    693697                self.privdropped = 0 
    694698         
     
    12261230        else :     
    12271231            # real file, just open it 
     1232            self.regainPriv() 
    12281233            self.logdebug("Opening data stream %s" % self.preserveinputfile) 
    12291234            self.jobSizeBytes = os.stat(self.preserveinputfile)[6] 
    1230             return open(self.preserveinputfile, "rb") 
     1235            infile = open(self.preserveinputfile, "rb") 
     1236            self.dropPriv() 
     1237            return infile 
    12311238         
    12321239    def closeJobDataStream(self) :