Re: [hackers] Re: [st][PATCH] Set minimum window size to avoid crash when resizing out of bounds

2018-05-17 Thread Eric Pruitt
On Fri, May 18, 2018 at 12:12:32AM +0200, Michael Buch wrote: > Nvm, that's the correct patch. Got confused by it auto-replying to the > thread... It didn't at least as far as Mutt is concerned. Are you using the Gmail web UI? I think the Gmail web UI will treat emails with the same title as part

[hackers] [slstatus] [PATCH] Audit slstatus.c

2018-05-17 Thread Laslo Hunhold
Good evening, I sat down and audited slstatus.c. All the changes are neatly listed in the patch description. With best regards Laslo Hunhold -- Laslo Hunhold >From 7999ad04385bc152f6696caf92b43ef69993bf89 Mon Sep 17 00:00:00 2001 From: Laslo Hunhold Date: Fri,

[hackers] Re: [st][PATCH] Set minimum window size to avoid crash when resizing out of bounds

2018-05-17 Thread Michael Buch
Whoops, my git-email messed up when trying to resend the patch. Apologies 2018-05-18 0:02 GMT+02:00 Michael Buch : > The terminal window is created without lower/upper bounds > for window width/height. On resizing the terminal to a size > of 1x1 or below we crash. This

[hackers] [st][PATCH] Set minimum window size to avoid crash when resizing out of bounds

2018-05-17 Thread Michael Buch
The terminal window is created without lower/upper bounds for window width/height. On resizing the terminal to a size of 1x1 or below we crash. This patch sets the minimum window height and width to prevent resizing past this size and handling the scenario similar to other terminals. --- x.c | 6

[hackers] [slstatus] Properly handle *snprintf() errors || Laslo Hunhold

2018-05-17 Thread git
commit c83b388a3f8f7a8c8d5a5cfddb6ab397005371a1 Author: Laslo Hunhold AuthorDate: Thu May 17 23:23:28 2018 +0200 Commit: Aaron Marcher CommitDate: Thu May 17 23:26:56 2018 +0200 Properly handle *snprintf() errors Posix guarantees that the

Re: [hackers] [slstatus] wifi: Change memmove to memcpy on OpenBSD || Aaron Marcher

2018-05-17 Thread Anselm Garbe
On 17 May 2018 at 13:29, isabella parakiss wrote: > why >nr_macaddr is unlikely overlapping with bssid.i_bssid. -Anselm

Re: [hackers] [slstatus] wifi: Change memmove to memcpy on OpenBSD || Aaron Marcher

2018-05-17 Thread isabella parakiss
why On 5/17/18, g...@suckless.org wrote: > commit ca8a146f03622149fbf9378e72b6ca02f25c5e55 > Author: Aaron Marcher > AuthorDate: Thu May 17 18:08:31 2018 +0200 > Commit: Aaron Marcher > CommitDate: Thu May 17 18:08:31 2018 +0200 > >

Re: [hackers] [slstatus][PATCH] suggestion: add user defined format callback

2018-05-17 Thread Aaron Marcher
Tobias, What do you think about a callback function where the user could define more precisely how formatting is done (like adding symbols for percentages etc.) I really like the idea and your proof of concept. Thanks for coming up with this! However I'd suggest to implement this more

[hackers] [slstatus][PATCH] suggestion: add user defined format callback

2018-05-17 Thread Tobias Tschinkowitz
Hi! This is just a suggestion, so not really something to commit right away. What do you think about a callback function where the user could define more precisely how formatting is done (like adding symbols for percentages etc.) I just prepared a little patch to show what i mean. Greetings,

[hackers] [slstatus] Mark unused parameters, fix compiler warnings || Aaron Marcher

2018-05-17 Thread git
commit fc8b6f81a54810faa844ea21d08ef47f95b8f4e0 Author: Aaron Marcher AuthorDate: Thu May 17 18:29:25 2018 +0200 Commit: Aaron Marcher CommitDate: Thu May 17 18:29:25 2018 +0200 Mark unused parameters, fix compiler warnings diff --git

[hackers] [slstatus] wifi: Change memmove to memcpy on OpenBSD || Aaron Marcher

2018-05-17 Thread git
commit ca8a146f03622149fbf9378e72b6ca02f25c5e55 Author: Aaron Marcher AuthorDate: Thu May 17 18:08:31 2018 +0200 Commit: Aaron Marcher CommitDate: Thu May 17 18:08:31 2018 +0200 wifi: Change memmove to memcpy on OpenBSD diff --git a/components/wifi.c

[hackers] [slstatus] Unify type of in for loops || Aaron Marcher

2018-05-17 Thread git
commit 7ab183c97f2de4eee3fa47a4c060740d45835541 Author: Aaron Marcher AuthorDate: Thu May 17 18:05:38 2018 +0200 Commit: Aaron Marcher CommitDate: Thu May 17 18:05:38 2018 +0200 Unify type of in for loops diff --git a/components/battery.c

[hackers] [slstatus] wifi: Fix order and add missing header || Aaron Marcher

2018-05-17 Thread git
commit 977be0cf4f369f586d0606887498066ee0565e2f Author: Aaron Marcher AuthorDate: Thu May 17 18:14:08 2018 +0200 Commit: Aaron Marcher CommitDate: Thu May 17 18:14:08 2018 +0200 wifi: Fix order and add missing header is needed before on

[hackers] [slstatus] wifi_essid: Fix coding style || Aaron Marcher

2018-05-17 Thread git
commit 1c44d404f602a7e477def6572c2f620a6970b244 Author: Aaron Marcher AuthorDate: Thu May 17 17:59:05 2018 +0200 Commit: Aaron Marcher CommitDate: Thu May 17 17:59:05 2018 +0200 wifi_essid: Fix coding style Only initialize variables at the

[hackers] [slstatus] Unify type of `i` in for loops || Aaron Marcher

2018-05-17 Thread git
commit 7be675f154e3922fb8e2c9309b48f9fa12869817 Author: Aaron Marcher AuthorDate: Thu May 17 17:40:11 2018 +0200 Commit: Aaron Marcher CommitDate: Thu May 17 17:42:26 2018 +0200 Unify type of `i` in for loops int for normal indexes size_t

[hackers] [slstatus] Change done to int as it is the CPU's natural type || Aaron Marcher

2018-05-17 Thread git
commit f9609f4ff421787bfa46b8f1c6ef2419b7679f7b Author: Aaron Marcher AuthorDate: Thu May 17 17:28:32 2018 +0200 Commit: Aaron Marcher CommitDate: Thu May 17 17:28:32 2018 +0200 Change done to int as it is the CPU's natural type diff --git

[hackers] [slstatus] Add comments for battery_* functions on OpenBSD || Aaron Marcher

2018-05-17 Thread git
commit 0892a93dbd694a9fb131af0b42b5691b8f4daa1e Author: Aaron Marcher AuthorDate: Thu May 17 17:24:47 2018 +0200 Commit: Aaron Marcher CommitDate: Thu May 17 17:24:47 2018 +0200 Add comments for battery_* functions on OpenBSD diff --git

[hackers] [slstatus] Change interval to unsigned int || Aaron Marcher

2018-05-17 Thread git
commit 11ce8ed0136112138606895754297454f4601e67 Author: Aaron Marcher AuthorDate: Thu May 17 17:25:31 2018 +0200 Commit: Aaron Marcher CommitDate: Thu May 17 17:25:31 2018 +0200 Change interval to unsigned int diff --git a/config.def.h b/config.def.h

Re: [hackers] [slstatus][PATCH] added comment for temp function (openbsd)

2018-05-17 Thread Aaron Marcher
Tobias, Somehow the patch failes to apply with `git am` with the message "git diff header lacks filename information when removing 1 leading pathname component". I would like to avoid applying it using "git apply" as this strips you as the author. Could you resend it again? I read the patch

[hackers] [slstatus] added comment for temp function (openbsd) || Tobias Tschinkowitz

2018-05-17 Thread git
commit 1cb5af98e5c58f1336f48046eaa1bb1b0b4e6a4c Author: Tobias Tschinkowitz AuthorDate: Thu May 17 13:19:29 2018 +0200 Commit: Aaron Marcher CommitDate: Thu May 17 17:13:28 2018 +0200 added comment for temp function (openbsd) diff --git

Re: [hackers] [slstatus] added wifi functionality for openbsd || Tobias Tschinkowitz

2018-05-17 Thread Dimitris Papastamos
On Wed, May 16, 2018 at 11:20:24PM +0200, g...@suckless.org wrote: > commit 1fc5cf00166a5dfefa89c3d6abbe92fedaf71e27 > Author: Tobias Tschinkowitz > AuthorDate: Wed May 16 22:37:43 2018 +0200 > Commit: Aaron Marcher > CommitDate: Wed May 16 22:52:14 2018

Re: [hackers] [slstatus][PATCH] added comment for temp function (openbsd)

2018-05-17 Thread Aaron Marcher
Tobias, Thank you for the small change. Somehow the patch failes to apply with `git am` with the message "git diff header lacks filename information when removing 1 leading pathname component". I would like to avoid applying it using "git apply" as this strips you as the author. Could you

Re: [hackers] [slstatus][patch] corrected calculations for disk space

2018-05-17 Thread Aaron Marcher
Tobias, i checked the complete functionality now for openbsd and had just some different values for my disk space (compared it to df(1)). Thank you, I applied the patch! I think on Linux some values differ to, I will have to further investige later though. Cheers! Aaron -- Web:

Re: [hackers] [st][PATCH] Set minimum window size to avoid crash when resizing out of bounds

2018-05-17 Thread Michael Buch
Resized the terminal window inwards until it crashed. Using floating window on dwm it didnt consistently crash. I was using xfce however. On Thu, 17 May 2018 at 13:04, Hiltjo Posthuma wrote: > On Wed, May 16, 2018 at 09:36:03PM +0100, michaelbuc...@gmail.com wrote: > >

Re: [hackers] [st][PATCH] Set minimum window size to avoid crash when resizing out of bounds

2018-05-17 Thread Hiltjo Posthuma
On Wed, May 16, 2018 at 09:36:03PM +0100, michaelbuc...@gmail.com wrote: > From: Michael Buch > > The termianl window is created without lower/upper bounds for window > width/height. On resizing the terminal to a size of 1x1 or below we crash. > This patch sets the

[hackers] [slstatus][PATCH] added comment for temp function (openbsd)

2018-05-17 Thread Tobias Tschinkowitz
--- config.def.h | 1 + 1 file changed, 1 insertion(+) diff --git config.def.h config.def.h index ef64b16..00796c6 100644 --- config.def.h +++ config.def.h @@ -43,6 +43,7 @@ static const char unknown_str[] = "n/a"; * swap_usedused swap in GB NULL * temp

Re: [hackers] [st][PATCH] Set minimum window size to avoid crash when resizing out of bounds

2018-05-17 Thread Silvan Jegen
Hi Thanks for the patch! Some comments below. On Wed, May 16, 2018 at 10:36 PM wrote: > From: Michael Buch > The termianl window is created without lower/upper bounds for window width/height. On resizing the terminal to a size of 1x1 or

[hackers] [slstatus][patch] corrected calculations for disk space

2018-05-17 Thread Tobias Tschinkowitz
Hi Aaron, i checked the complete functionality now for openbsd and had just some different values for my disk space (compared it to df(1)). The rest is working fine! Greets, Tobias --- components/disk.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git components/disk.c