From 219c4de08f240320cae96e0a5a4a082db45a06da Mon Sep 17 00:00:00 2001 From: nicolargo Date: Mon, 20 Jul 2020 10:52:54 +0200 Subject: class AmpsList method _build_amps_list() Windows fail (glances/amps_list.py) #1689 --- glances/amps_list.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/glances/amps_list.py b/glances/amps_list.py index f369cda9..a0b71d7d 100644 --- a/glances/amps_list.py +++ b/glances/amps_list.py @@ -2,7 +2,7 @@ # # This file is part of Glances. # -# Copyright (C) 2019 Nicolargo +# Copyright (C) 2020 Nicolargo # # Glances is free software; you can redistribute it and/or modify # it under the terms of the GNU Lesser General Public License as published by @@ -145,6 +145,9 @@ class AmpsList(object): if (re.search(amp_value.regex(), p['name']) is not None): add_it = True else: + if p['cmdline'] is None: + # See issue #1689 (thanks to @darylkell) + continue for c in p['cmdline']: if (re.search(amp_value.regex(), c) is not None): add_it = True -- cgit v1.2.3