Skip to content

Commit

Permalink
String: fix it up to work with the previously committed enhancement f…
Browse files Browse the repository at this point in the history
…or subprocess timeout.

Conflicts:

	plugins/String/plugin.py
  • Loading branch information
Daniel Folkinshteyn authored and progval committed Aug 12, 2011
1 parent 3526d5d commit 91ac1c2
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
12 changes: 8 additions & 4 deletions plugins/String/plugin.py
Expand Up @@ -146,10 +146,14 @@ def re(self, irc, msg, args, ff, text):
s = _('You probably don\'t want to match the empty string.')
irc.error(s)
else:
irc.reply(f(text))
re = wrap(re, [('checkCapability', 'trusted'),
first('regexpMatcher', 'regexpReplacer'),
'text'])
t = self.registryValue('re.timeout')
try:
v = commands.process(f, text, timeout=t, pn=self.name(), cn='re')
irc.reply(v)
except commands.ProcessTimeoutError, e:
irc.error("ProcessTimeoutError: %s" % (e,))
re = thread(wrap(re, [first('regexpMatcher', 'regexpReplacer'),
'text']))

@internationalizeDocstring
def xor(self, irc, msg, args, password, text):
Expand Down
2 changes: 1 addition & 1 deletion src/version.py
@@ -1,3 +1,3 @@
"""stick the various versioning attributes in here, so we only have to change
them once."""
version = '0.83.4.1+limnoria (2011-08-13T01:53:58+0200)'
version = '0.83.4.1+limnoria (2011-08-13T01:55:24+0200)'

0 comments on commit 91ac1c2

Please sign in to comment.