client: fix spurious newlines in station show
PATCH 1/2 client: fix spurious newlines in station show
This change removes duplicated calls to display_table_footer(), in station show.
Before this change, the bug caused an extra newline to be output every time the table updated. This only occurred when the network was disconnected.
$ iwctl
[iwd]# station wlan0 show--- client/station.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-)
client/station.c +1 -7
@@ -217,15 +217,9 @@ static void display_station(const char *device_name, 47, network_get_name(station->connected_network));display_addresses (device_name); - -/* -* If connected the diagnostic interface is presumably up so -* don't add the table footer just yet. -*/ -return ; } -display_table_footer (); +/* The table footer is handled by cmd_show. */ }static void display_station_inline (const char *margin,const void *data)
Signature · 1 line
2.38.1
PATCH 2/2 gitignore: add .cache
This directory is used by clangd.
--- .gitignore | 1 + 1 file changed, 1 insertion(+)
.gitignore +1 -0
@@ -4,6 +4,7 @@ .libs .deps .dirstamp +.cache tags cscope.* Makefile
Signature · 1 line
2.38.1
Quoted 32 lines · On Wed, 2022-11-02 at 14:51 +0530, eNV25 wrote:
This change removes duplicated calls to
display_table_footer(), in station show.Before this change, the bug caused an extra newline to be output every
time the table updated. This only occurred when the network was disconnected.$ iwctl [iwd]# station wlan0 show---
client/station.c | 8 +-------1 file changed, 1 insertion(+), 7 deletions(-)client/station.c +0
-0@@ -217,15 +217,9 @@ static void display_station(const char *device_name,47, network_get_name(station-
Quoted 1 line
connected_network));
display_addresses(device_name);
-
- /*
- * If connected the diagnostic interface is presumably up so
- * don't add the table footer just yet. - */
- return;
Quoted 8 lines
}
- display_table_footer();
+ /* The table footer is handled bycmd_show. */ }
static voiddisplay_station_inline(const char *margin, const void *data)
LGTM, I noticed this happening but never spent the time to diagnose it. Thanks!
Hi,
Quoted 7 lines · On 11/2/22 04:21, eNV25 wrote:
This change removes duplicated calls to
display_table_footer(), in station show.Before this change, the bug caused an extra newline to be output every time the table updated. This only occurred when the network was disconnected.
Quoted 7 lines
$ iwctl [iwd]# station wlan0 show--- client/station.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-)
Can I get a proper full name please? I can't take this into the repo otherwise.
Regards,
-Denis
Quoted 1 line · Denis Kenzior
Can I get a proper full name please? I can't take this into the repo otherwise.
My name is Neehar Vijay.
Do I need to send a v2 patch with the name?
Quoted 2 lines
Regards,
-Denis