← Back to team overview

apport-hackers team mailing list archive

[Merge] lp:~mathieu-tl/apport/attach_wifi_regex into lp:apport

 

Mathieu Trudel-Lapierre has proposed merging lp:~mathieu-tl/apport/attach_wifi_regex into lp:apport.

Requested reviews:
  Apport upstream developers (apport-hackers)
Related bugs:
  Bug #732917 in apport (Ubuntu): "attach_wifi() hook util omits some information"
  https://bugs.launchpad.net/ubuntu/+source/apport/+bug/732917

For more details, see:
https://code.launchpad.net/~mathieu-tl/apport/attach_wifi_regex/+merge/52939

Fixes the regex to correctly catch NetworkManager, modem-manager, etc. with the PID included in syslog entries.
-- 
https://code.launchpad.net/~mathieu-tl/apport/attach_wifi_regex/+merge/52939
Your team Apport upstream developers is requested to review the proposed merge of lp:~mathieu-tl/apport/attach_wifi_regex into lp:apport.
=== modified file 'apport/hookutils.py'
--- apport/hookutils.py	2011-02-28 10:58:32 +0000
+++ apport/hookutils.py	2011-03-10 22:32:52 +0000
@@ -468,7 +468,7 @@
 def attach_wifi(report):
     '''Attach wireless (WiFi) network information to report.'''
 
-    report['WifiSyslog'] = recent_syslog(re.compile(r'(NetworkManager|modem-manager|dhclient|kernel):'))
+    report['WifiSyslog'] = recent_syslog(re.compile(r'(NetworkManager|modem-manager|dhclient|kernel)(\[\d+\])?:'))
     report['IwConfig'] = re.sub('Encryption key:(.*)', 'Encryption key: <hidden>', command_output(['iwconfig']))
     report['RfKill'] = command_output(['rfkill', 'list'])
     report['CRDA'] = command_output(['iw', 'reg', 'get'])