Overview
Comment: | extra space, support for IPv6 |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | master | trunk |
Files: | files | file ages | folders |
SHA3-256: |
5d265df0fca38ee22b84f90ee722e816 |
User & Date: | arcade@b1t.name on 2012-12-10 13:04:57.000 |
Other Links: | branch diff | manifest | tags |
Context
2013-01-24
| ||
13:38 | fixing bug with too big error message flowing to syslog check-in: 46225bbe65 user: arcade@b1t.name tags: master, trunk | |
2012-12-10
| ||
13:04 | extra space, support for IPv6 check-in: 5d265df0fc user: arcade@b1t.name tags: master, trunk | |
2012-07-10
| ||
14:02 | remove leftover fix conversion from multibyte check-in: dbc0727869 user: arcade@b1t.name tags: master, trunk | |
Changes
Modified squid-tagger.py
from [29eb01c1f2]
to [55bfbe8f1e].
︙ | ︙ | |||
193 194 195 196 197 198 199 | # storing fileno self._fileno = fd.fileno() # creating interface self._io = io.FileIO(self._fileno, 'w', closefd) # using empty tail self._tail = None # putting file to nonblocking mode | | | 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 | # storing fileno self._fileno = fd.fileno() # creating interface self._io = io.FileIO(self._fileno, 'w', closefd) # using empty tail self._tail = None # putting file to nonblocking mode fcntl.fcntl(self._fileno, fcntl.F_SETFL, fcntl.fcntl(self._fileno, fcntl.F_GETFL) | os.O_NONBLOCK) def __del__(self): # purge queue before deleting if not self.empty(): self.join() def put(self, item, block=True, timeout=None): |
︙ | ︙ | |||
297 298 299 300 301 302 303 | class Checker(object): __slots__ = frozenset(['_db', '_log', '_queue', '_request', '_stdout']) def __init__(self, queue, logger): self._db = tagDB() self._log = logger self._log.info('started') | | | 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 | class Checker(object): __slots__ = frozenset(['_db', '_log', '_queue', '_request', '_stdout']) def __init__(self, queue, logger): self._db = tagDB() self._log = logger self._log.info('started') self._request = re.compile('^([0-9]+)\ (http|ftp):\/\/([-\w.:]+)\/([^ ]*)\ ([0-9.:]+)\/(-|[\w\.]+)\ (-|\w+)\ (-|GET|HEAD|POST).*$') self._queue = queue self._stdout = FWritelineQueue(sys.stdout, False) def process(self, id, site, ip_address, url_path, line = None): #self._log.info('trying {}'.format(site)) result = self._db.check(site, ip_address) reply = None |
︙ | ︙ |