Make GeneralLogParser.pm understand the "as" part of a Connect command.

This commit is contained in:
Daniel Nichter
2012-11-14 11:38:55 -07:00
parent 2c9ebf33e2
commit 9b105ee2d2
4 changed files with 61 additions and 4 deletions

View File

@@ -129,7 +129,8 @@ sub parse_event {
else {
# The Connect command may or may not be followed by 'on'.
# When it is, 'on' may or may not be followed by a database.
my ($user, undef, $db) = $arg =~ /(\S+)/g;
my ($user) = $arg =~ m/(\S+)/;
my ($db) = $arg =~ m/on (\S+)/;
my $host;
($user, $host) = split(/@/, $user);
PTDEBUG && _d('Connect', $user, '@', $host, 'on', $db);