pidcat icon indicating copy to clipboard operation
pidcat copied to clipboard

Fix blank line cause silent quit.

Open nomadalex opened this issue 7 years ago • 6 comments

when logcat output blank line, pidcat will silent quit.

nomadalex avatar Aug 05 '17 10:08 nomadalex

Hmm should we actually continue here? Or display the blank line?

JakeWharton avatar Aug 05 '17 22:08 JakeWharton

It is completely blank line, it is unnecessary to display it. Blank which application output will not be completely blank.

nomadalex avatar Aug 07 '17 02:08 nomadalex

Then why was it logged?

On Sun, Aug 6, 2017, 7:21 PM Kun Wang [email protected] wrote:

It is completely blank line, it is unnecessary to display it.

— You are receiving this because you commented.

Reply to this email directly, view it on GitHub https://github.com/JakeWharton/pidcat/pull/145#issuecomment-320553055, or mute the thread https://github.com/notifications/unsubscribe-auth/AAEEESSPiwLCxh47Vxn9JnjMNDIBtOx4ks5sVnS1gaJpZM4OubLq .

JakeWharton avatar Aug 07 '17 02:08 JakeWharton

I don't know, but it exists, I found it on huawei honor 6, below is raw output with print(repr(line)), the second line cause quit.

"int logctl_get(): open '/dev/hwlog_switch' fail -1, 13. Permission denied\r\n"
'\r\n'
'Note: log switch off, only log_main and log_events will have logs!\r\n'
'--------- beginning of system\r\n'
'V/ToolboxContentView( 4766): onReceive:action ACTION_STATE_CHANGED\r\n'
'V/ToolboxContentView( 4766): onReceive:action ACTION_STATE_CHANGED\r\n'
'V/ToolboxContentView( 4766): onReceive:action ACTION_STATE_CHANGED\r\n'
'D/ConnectivityService( 4261): registerNetworkAgent NetworkAgentInfo{ ni{[type: WIFI[], state: CONNECTING/CONNECTING, reason: (unspecified), extra: "360WiFi-xiuusei", roaming: false, failover: false, isAvailable: true]}  network{100}  lp{{LinkAddresses: []  Routes: [] DnsAddresses: [] Domains: null MTU: 0 TcpBufferSizes: 524288,1048576,2097152,262144,524288,1048576}}  nc{[ Transports: WIFI Capabilities: INTERNET&NOT_RESTRICTED&TRUSTED&NOT_VPN LinkUpBandwidth>=1048576Kbps LinkDnBandwidth>=1048576Kbps]}  Score{60}  everValidated{false}  lastValidated{false}  created{false} lingering{false} explicitlySelected{false} acceptUnvalidated{false} everCaptivePortalDetected{false} lastCaptivePortalDetected{false} }\r\n'
'D/ConnectivityService( 4261): Got NetworkAgent Messenger\r\n'
'D/ConnectivityService( 4261): NetworkAgentInfo [WIFI () - 100] EVENT_NETWORK_INFO_CHANGED, going from null to CONNECTING\r\n'
'D/HwConnectivityService( 4261): hintUserSwitchToMobileWhileWifiDisconnected, state=CONNECTING  type =1\r\n'
'D/HwConnectivityService( 4261): mLastWifiState =DISCONNECTED\r\n'
'D/HwConnectivityService( 4261): [enter]handleLteMobileDataStateChange type=1,subType=0\r\n'
'D/HwConnectivityService( 4261): csagent WIFI NetworkAgent regist as netid: 100, mWifiNetworkMessenger=android.os.Messenger@a22f484\r\n'
'D/ConnectivityService( 4261): NetworkAgent connected\r\n'
'D/HwConnectivityService( 4261): mIntentReceiver begin\r\n'
'D/HwConnectivityService( 4261): CtrlSocket Receiver,disable: false locked: false action: android.net.wifi.STATE_CHANGE mSmartKeyguardLevel: normal_level mStartPowerSaving: false\r\n'
'D/WifiService( 4261): onReceive, action:android.net.wifi.STATE_CHANGE\r\n'
'D/NetdConnector( 4261): SND -> {205 interface ipv6 wlan0 enable}\r\n'
'D/FrameworkListener( 3726): dispatchCommand cmdNum = 205, argv[0] = interface\r\n'
'W/SocketListener( 3726): sending broadcast to Pid = 4261, Uid = 1000 \r\n'
'W/SocketListener( 3726): sending broadcast to Pid = 4261, Uid = 1000 \r\n'
'D/NetdConnector( 4261): RCV <- {200 205 IPv6 state changed}\r\n'
'D/NetdConnector( 4261): RCV <- {200 205 IPv6 state changed}\r\n'
'D/NetdConnector( 4261): RCV <- {616 Route updated fe80::/64 dev wlan0}\r\n'
'D/NetdConnector( 4261): RCV <- {616 Route updated fe80::/64 dev wlan0}\r\n'
'D/NetdConnector( 4261): RCV <- {614 Address updated fe80::5a1f:28ff:fe0a:1642/64 wlan0 196 253}\r\n'
'D/NetdConnector( 4261): RCV unsolicited event from native daemon, event = 616 Route updated fe80::/64 dev wlan0\r\n'
'D/NetdConnector( 4261): RCV <- {614 Address updated fe80::5a1f:28ff:fe0a:1642/64 wlan0 196 253}\r\n'
'D/NetdConnector( 4261): SND -> {206 interface setcfg wlan0 0.0.0.0 0}\r\n'
'D/FrameworkListener( 3726): dispatchCommand cmdNum = 206, argv[0] = interface\r\n'
'D/NetdConnector( 4261): RCV <- {200 206 Interface configuration set}\r\n'
'D/NetdConnector( 4261): RCV <- {200 206 Interface configuration set}\r\n'

nomadalex avatar Aug 08 '17 03:08 nomadalex

hello?

nomadalex avatar Aug 21 '17 11:08 nomadalex

Hi, I reach the same problem with Huawei device and this PR fixes the silent quit.

rodriamaro avatar May 22 '18 15:05 rodriamaro