????JFIF??x?x????'
Server IP : 79.136.114.73 / Your IP : 216.73.216.163 Web Server : Apache/2.4.7 (Ubuntu) PHP/5.5.9-1ubuntu4.29 OpenSSL/1.0.1f System : Linux b8009 3.13.0-170-generic #220-Ubuntu SMP Thu May 9 12:40:49 UTC 2019 x86_64 User : www-data ( 33) PHP Version : 5.5.9-1ubuntu4.29 Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority, MySQL : ON | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /proc/self/root/home/b8009/Python-3.6.3/Tools/scripts/ |
Upload File : |
#! /usr/bin/env python3 # Check that all ".pyc" files exist and are up-to-date # Uses module 'os' import sys import os from stat import ST_MTIME import importlib.util # PEP 3147 compatibility (PYC Repository Directories) cache_from_source = (importlib.util.cache_from_source if sys.implementation.cache_tag else lambda path: path + 'c') def main(): if len(sys.argv) > 1: verbose = (sys.argv[1] == '-v') silent = (sys.argv[1] == '-s') else: verbose = silent = False MAGIC = importlib.util.MAGIC_NUMBER if not silent: print('Using MAGIC word', repr(MAGIC)) for dirname in sys.path: try: names = os.listdir(dirname) except OSError: print('Cannot list directory', repr(dirname)) continue if not silent: print('Checking ', repr(dirname), '...') for name in sorted(names): if name.endswith('.py'): name = os.path.join(dirname, name) try: st = os.stat(name) except OSError: print('Cannot stat', repr(name)) continue if verbose: print('Check', repr(name), '...') name_c = cache_from_source(name) try: with open(name_c, 'rb') as f: magic_str = f.read(4) mtime_str = f.read(4) except IOError: print('Cannot open', repr(name_c)) continue if magic_str != MAGIC: print('Bad MAGIC word in ".pyc" file', end=' ') print(repr(name_c)) continue mtime = get_long(mtime_str) if mtime in {0, -1}: print('Bad ".pyc" file', repr(name_c)) elif mtime != st[ST_MTIME]: print('Out-of-date ".pyc" file', end=' ') print(repr(name_c)) def get_long(s): if len(s) != 4: return -1 return s[0] + (s[1] << 8) + (s[2] << 16) + (s[3] << 24) if __name__ == '__main__': main()