Re: [hackers] Little bug on dmenu

2018-01-04 Thread Hiltjo Posthuma
On Thu, Jan 04, 2018 at 12:47:02PM +, Vincent Carluer wrote: > Hello, > > First of all, thank you for your softwares :D > I found a little bug on last git version of dmenu which prevent to build it > without XINEMARA. > You will find the corresponding patch in this mail. > > Regards, > >

Re: [hackers] [st][PATCH] Apply ATTR_REVERSE after ATTR_FAINT

2017-12-26 Thread Hiltjo Posthuma
On Tue, Dec 26, 2017 at 04:38:27PM +0100, Benno Fünfstück wrote: > An example where the new behaviour makes more sense: > > Suppose some text is formatted with ATTR_FAINT for red for the foreground, so > it > is rendered in a dark red. In that case, when selected with the mouse, the > intended

Re: [hackers] [dwm][PATCH] Add new barmargin option

2017-12-12 Thread Hiltjo Posthuma
On Tue, Dec 12, 2017 at 09:51:08AM +0100, David Demelier wrote: > The current code has a fixed margins of 2, add a compile time tunable to > edit it > --- > config.def.h | 1 + > dwm.c| 2 +- > 2 files changed, 2 insertions(+), 1 deletion(-) > > diff --git a/config.def.h b/config.def.h >

Re: [hackers] Re: [dmenu][PATCH] make prompt padding symmetric

2017-12-07 Thread Hiltjo Posthuma
On Thu, Dec 07, 2017 at 10:51:17PM +0100, Alessandro Caputo wrote: >Sorry, forgot to add some info. >At least on my two computers and with the fonts I tested, there's a >problem with the padding of dmenu's prompt. >I have attached two screenshots with simply an 'O' as prompt, and

Re: [hackers] [lsw][patch] Better handling of window title with non-ascii chars

2017-11-25 Thread Hiltjo Posthuma
On Fri, Nov 24, 2017 at 04:53:16PM +0100, Silvan Jegen wrote: > On Fri, Nov 24, 2017 at 12:35 PM, Hiltjo Posthuma > <hil...@codemadness.org> wrote: > > On Wed, Nov 22, 2017 at 10:47:39PM +0100, Julien Steinhauser wrote: > >> Hello > >> > >> I've seen

Re: [hackers] [lsw][patch] Better handling of window title with non-ascii chars

2017-11-24 Thread Hiltjo Posthuma
On Wed, Nov 22, 2017 at 10:47:39PM +0100, Julien Steinhauser wrote: > Hello > > I've seen window title with non-ascii chars incorrectly displayed, > using Xutf8TextPropertyToTextList instead of XmbTextPropertyToTextList > as in the diff below fixed it. > > Regards > > Julien > > diff --git

Re: [hackers] [swerc] use png logo again || Hiltjo Posthuma

2017-11-21 Thread Hiltjo Posthuma
On Tue, Nov 21, 2017 at 08:20:00PM +0100, Markus Teich wrote: > Laslo Hunhold wrote: > > I understand the reasons for the switch, most prominently the security > > implications for people visiting suckless.org with the Tor-browser > > (because SVGs can contain embedded javascript). > >

Re: [hackers] [st] Xresources colors 0-15 and font-faces

2017-11-10 Thread Hiltjo Posthuma
On Fri, Nov 10, 2017 at 02:01:38PM +0100, Tony Wooster wrote: >Hi, >First-time contributor. >I made a patch for adding runtime configuration of colors and >font-faces from Xresources. It wasn't clear whether the non-goal of >"color filters" applied to this (could someone

Re: [hackers] [dmenu][PATCH v2] Set class name on menu window

2017-11-03 Thread Hiltjo Posthuma
On Fri, Nov 03, 2017 at 09:49:10AM -0700, Omar Sandoval wrote: > WM_CLASS is a standard ICCCM property which is used to identify windows. > Window managers and compositors use it to allow per-application > configurable behavior. > --- > Thanks, Devin, that's much cleaner. > > dmenu.c | 2 ++ > 1

Re: [hackers] [dwm] [PATCH v3] Set class name on status bar

2017-11-03 Thread Hiltjo Posthuma
On Fri, Nov 03, 2017 at 09:58:38AM -0700, Omar Sandoval wrote: > This is useful for configuring compositors to ignore the status bar > window. > --- > As Devin pointed out in the dmenu thread, there's no reason to > dynamically allocate ch at all. > > dwm.c | 2 ++ > 1 file changed, 2

Re: [hackers] [dmenu] [PATCH] Set class name on menu window

2017-11-02 Thread Hiltjo Posthuma
On Thu, Nov 02, 2017 at 10:29:15AM -0700, Omar Sandoval wrote: > On Thu, Nov 02, 2017 at 06:19:44PM +0100, Hiltjo Posthuma wrote: > > On Thu, Nov 02, 2017 at 02:10:35AM -0700, Omar Sandoval wrote: > > > This is useful for, e.g., compton. > > > --- > > > dmenu.

Re: [hackers] [st][PATCH] in bracketed paste mode, filter escapes from pasted data

2017-11-02 Thread Hiltjo Posthuma
On Thu, Nov 02, 2017 at 10:42:05PM +0100, Jann Horn wrote: > Browsers permit copied data to contain escape characters. To prevent > malicious websites (or other sources of malicious text) from faking a > bracketed paste end sequence, filter escape characters from pasted text in > bracketed paste

Re: [hackers] [dmenu] [PATCH] Set class name on menu window

2017-11-02 Thread Hiltjo Posthuma
On Thu, Nov 02, 2017 at 02:10:35AM -0700, Omar Sandoval wrote: > This is useful for, e.g., compton. > --- > dmenu.c | 8 > 1 file changed, 8 insertions(+) > > diff --git a/dmenu.c b/dmenu.c > index d605ab4..2a16ad8 100644 > --- a/dmenu.c > +++ b/dmenu.c > @@ -545,6 +545,7 @@ setup(void)

Re: [hackers] [dwm] fix keysyms processing by kfx_

2017-10-09 Thread Hiltjo Posthuma
On Sun, Oct 08, 2017 at 08:23:59AM +0200, Anselm Garbe wrote: > Hi Hiltjo, > > I don't really like this change, see below for the reasons. > > On 30 September 2017 at 12:39, Hiltjo Posthuma <hil...@codemadness.org> wrote: > > --- a/dwm.c > > +++ b/dwm

Re: [hackers] [st] Refactoring (-61 lines)

2017-10-01 Thread Hiltjo Posthuma
On Sun, Sep 24, 2017 at 04:11:22PM -0500, Devin J. Pohly wrote: > Some refactoring on the st codebase, reducing it by 61 lines and > establishing cleaner separation between st.c and x.c. There are 28 > fewer extern variables, and and X-specific types are now > included only in x.c. > > These

[hackers] [dwm] fix keysyms processing by kfx_

2017-09-30 Thread Hiltjo Posthuma
th XGetKeyboardMapping and enables the warning again. Any thoughts? >From 2faa3cf44090d24a11c549fc1e4eb737fbc813af Mon Sep 17 00:00:00 2001 From: Hiltjo Posthuma <hil...@codemadness.org> Date: Sat, 30 Sep 2017 12:26:00 +0200 Subject: [PATCH] fix keysyms processing by kfx_ --- config.mk |

Re: [hackers] [tabbed][PATCH] Fix minor inconsistency in man page

2017-09-29 Thread Hiltjo Posthuma
On Thu, Sep 28, 2017 at 03:36:12PM +0200, Alessandro Caputo wrote: > --- > tabbed.1 | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/tabbed.1 b/tabbed.1 > index bc28b8c..07bdbd7 100644 > --- a/tabbed.1 > +++ b/tabbed.1 > @@ -131,7 +131,7 @@ toggle autofocus of urgent tabs

Re: [hackers] [surf][PATCH] add support for WebGL

2017-09-25 Thread Hiltjo Posthuma
On Sun, Sep 24, 2017 at 10:35:45PM +0900, Eon S. Jeon wrote: > --- > config.def.h | 1 + > surf.c | 5 + > 2 files changed, 6 insertions(+) > > diff --git a/config.def.h b/config.def.h > index 2e735bf..ec99e27 100644 > --- a/config.def.h > +++ b/config.def.h > @@ -46,6 +46,7 @@ static

Re: [hackers] [surf][PATCH] Adapting the `homepage` patch to version 2.0

2017-09-19 Thread Hiltjo Posthuma
On Tue, Sep 19, 2017 at 11:21:55PM +0200, Jaume Devesa wrote: > This trivial commit adapts the _homepage patch_ [1] at the current > version of surf (2.0) > > [1]: https://surf.suckless.org/patches/homepage > --- > config.def.h | 1 + > surf.c | 6 +- > 2 files changed, 6

Re: [hackers] Re: [st] Patch: XftFontOpenPattern failure

2017-09-15 Thread Hiltjo Posthuma
On Thu, Sep 14, 2017 at 04:44:46PM -0400, Gary Allen Vollink wrote: > Emg in IRC suggested an attachment version. > > On Thu, Sep 14, 2017 at 4:13 PM, Gary Allen Vollink wrote: > > --- > > x.c | 3 +++ > > 1 file changed, 3 insertions(+) > > > > diff --git a/x.c b/x.c > >

Re: [hackers] [PATCH][sbase] tar: use bigger buffer size to increase performance

2017-09-11 Thread Hiltjo Posthuma
On Sun, Sep 10, 2017 at 06:58:27PM +0200, Silvan Jegen wrote: > Hi Hiltjo > > Thanks for the review! > > On Sat, Sep 09, 2017 at 01:06:21PM +0200, Hiltjo Posthuma wrote: > > On Sat, Sep 09, 2017 at 11:08:42AM +0200, Silvan Jegen wrote: > > > From: Jim

Re: [hackers] [PATCH][sbase] tar: use bigger buffer size to increase performance

2017-09-09 Thread Hiltjo Posthuma
On Sat, Sep 09, 2017 at 11:08:42AM +0200, Silvan Jegen wrote: > From: Jim Beveridge > > The original code is by Jim Beveridge working on Fuchsia. I merged it > with slight changes. > To be clear: is it under the sbase LICENSE? > Time to tar two 1GB files: > > Before

Re: [hackers] [dwm][PATCH] move config data to read-only sections

2017-09-06 Thread Hiltjo Posthuma
On Wed, Sep 06, 2017 at 05:07:06PM +0200, Anselm R Garbe wrote: > Hi Joachim, > > On 6 September 2017 at 17:02, wrote: > > commit 6a5056d4c919bb5ae0222b2fde0ed787d50092cf > > Author: Joachim Henke > > AuthorDate: Wed, 6 Sep 2017

Re: [hackers] [surf] modal browsing

2017-09-03 Thread Hiltjo Posthuma
On Sun, Sep 03, 2017 at 01:59:44AM +0200, ssd wrote: > Hi, > > modal browsing hasn't been first class citizen in surf. but given the > recent activity in adding features and webkit2 may be there is a > slightly better chance now. > > attached is another rewrite of the modal browsing patch. > >

Re: [hackers] [sent] add slide numbers with configurable position and size

2017-09-02 Thread Hiltjo Posthuma
On Sat, Sep 02, 2017 at 11:01:03AM +0200, s...@mailless.org wrote: > > This adds a slide number to the bottom (left, right or middle) of the > slide. It uses the index in the fontlist to specify the font size for > the slide number. > > known issue: number is not shown on image slides. future

Re: [hackers] [st] make clipboard patch obsolete || Anselm R Garbe

2017-09-01 Thread Hiltjo Posthuma
On Fri, Sep 01, 2017 at 09:48:58AM +0200, g...@suckless.org wrote: > commit 77c51c5a6b16387f1792e23acbcf2080f790aa25 > Author: Anselm R Garbe > AuthorDate: Fri Sep 1 09:48:24 2017 +0200 > Commit: Anselm R Garbe > CommitDate: Fri Sep 1 09:48:24 2017 +0200

Re: [hackers] [sbase][PATCH] ls: abort a directory if we cannot opendir it

2017-08-22 Thread Hiltjo Posthuma
On Tue, Aug 22, 2017 at 04:51:37PM +1200, David Phillips wrote: > We should not try and perform operations on an invalid DIR* stream. > Instead, we shall let the error message be printed, and the return > code set (existing behaviour) and abort afterwards. > --- > ls.c | 1 + > 1 file changed, 1

Re: [hackers] More forgotten sbase/ubase patches

2017-08-22 Thread Hiltjo Posthuma
On Fri, Aug 11, 2017 at 09:01:01PM -0700, Michael Forney wrote: > I went looking through my sbase/ubase branches and found some more > forgotten patches. > > = sbase = > * http://lists.suckless.org/hackers/1702/14283.html > > sbase tar still needs a lot of work, but currently it is frustrating >

Re: [hackers] [st] Alpha patch needs update and bug fixing with Unicode input via dmenu

2017-07-16 Thread Hiltjo Posthuma
On Sun, Jul 16, 2017 at 11:29:18PM +0600, Techno Implant wrote: > 1.New update changes config.mk file so this patch gets rejected there. > 2. When alpha is set 0xff unicode input with i is > possible, for other values in alpha unicode input is not possible for > me. > From terminal I get this: >

Re: [hackers] [quark] Send absolute path when redirecting || Laslo Hunhold

2017-07-07 Thread Hiltjo Posthuma
On Fri, Jul 07, 2017 at 01:35:37PM +0200, g...@suckless.org wrote: > commit d598da3d52413b20cffe2c7f03c885ffdcca2818 > Author: Laslo Hunhold > AuthorDate: Fri Jul 7 13:33:43 2017 +0200 > Commit: Laslo Hunhold > CommitDate: Fri Jul 7 13:33:43 2017 +0200 > >

Re: [hackers] [quark] Fix dir-check in dirent || Laslo Hunhold

2017-06-28 Thread Hiltjo Posthuma
On Wed, Jun 28, 2017 at 08:30:13AM +0200, g...@suckless.org wrote: > commit 1e65a4848e04660ae4d471ef418993da6a7e > Author: Laslo Hunhold > AuthorDate: Wed Jun 28 08:29:31 2017 +0200 > Commit: Laslo Hunhold > CommitDate: Wed Jun 28 08:29:31 2017 +0200 >

Re: [hackers] [dmenu][PATCH] Don't display text directly when typing a password

2017-06-10 Thread Hiltjo Posthuma
On Sat, Jun 10, 2017 at 06:29:49PM +0200, Philip Kaludercic wrote: > From: Philip K > If this is meant for upstream a description would be nice, but this feature is beyond the scope of dmenu and won't be accepted. Some feedback below: > --- > dmenu.c | 19

Re: [hackers] [farbfeld] Makefile-workaround for OpenBSD || Laslo Hunhold

2017-05-29 Thread Hiltjo Posthuma
On Mon, May 29, 2017 at 07:15:15PM +0200, Laslo Hunhold wrote: > > As far as I can see it, we are left to write down each target > explicitly. Which is not an issue in my opinion in our case. Like I said on IRC: Generally speaking I'd prefer if the Makefile is 20 lines longer and very

[hackers] Re: [sbase] libutil/cp.c leaks

2017-05-12 Thread Hiltjo Posthuma
On Sun, May 07, 2017 at 01:54:42PM +0200, Hiltjo Posthuma wrote: > Hey, > > I think there are some cases where libutil/cp.c can leak file descriptors. > It is a warning case, but the descriptors are not closed. > > I think only `mv` is affected. > > P

[hackers] [sbase] libutil/cp.c leaks

2017-05-07 Thread Hiltjo Posthuma
Hey, I think there are some cases where libutil/cp.c can leak file descriptors. It is a warning case, but the descriptors are not closed. I think only `mv` is affected. Patch below: >From af392d1a764d7420c7b05bb9e13d7766a5979894 Mon Sep 17 00:00:00 2001 From: Hiltjo Posthuma &

Re: [hackers] [dwm] Center windows if useless gaps exist post applysizehints

2017-04-24 Thread Hiltjo Posthuma
Hey, I briefly tested the patch and it does not tile the window properly for me. It seems to overlap the st window even in tiled-mode. PS. Please use plain-text e-mail and don't top-post. -- Kind regards, Hiltjo

Re: [hackers] [dwm] Center windows if useless gaps exist post applysizehints

2017-04-24 Thread Hiltjo Posthuma
On Mon, Apr 24, 2017 at 01:35:59PM +1000, Daniel Cousens wrote: >It has often annoyed me that my `st` windows would have "gaps" beneath >them and to the right as a result of the size hints not being respected >(due to column widths being enforced nicely in `st`)... however, � the >

Re: [hackers] Repeated usage of m->lt[m->sellt]->arrange deduplication

2017-04-24 Thread Hiltjo Posthuma
On Mon, Apr 24, 2017 at 10:14:36AM +1000, Daniel Cousens wrote: >Indeed, � apologies for the style issues. >The argument could probably be const too. > >On 24 Apr. 2017 04:32, "Laslo Hunhold" <[1]d...@frign.de> wrote: > > On Sun, 23 Apr 2017 20:

Re: [hackers] Repeated usage of m->lt[m->sellt]->arrange deduplication

2017-04-23 Thread Hiltjo Posthuma
On Sun, Apr 23, 2017 at 11:54:31PM +1000, Daniel Cousens wrote: >I have found this pattern to take up significant parts of my time when >rebasing my changes onto suckless/master, � such that I feel the >following patch will both increase readability, � reduce diffs and >overall

Re: [hackers] [dmenu][PATCH] Output the element's position in the list instead of his name

2017-03-30 Thread Hiltjo Posthuma
On Thu, Mar 30, 2017 at 01:40:36PM +0200, Matteo Alessio Carrara wrote: >This patch facilitates writing wrappers to dmenu, because to understand >what has been selected by comparing strings is slower than using the >index of an array. Furthermore avoids ambiguity in the case that there

Re: [hackers] [farbfeld] Make Makefile strictly POSIX compliant || Laslo Hunhold

2017-03-30 Thread Hiltjo Posthuma
On Thu, Mar 30, 2017 at 08:44:34AM +0200, g...@suckless.org wrote: > commit bbe28227eb80da62fec59aa79ba7a97f5c3937b4 > Author: Laslo Hunhold > AuthorDate: Thu Mar 30 08:41:17 2017 +0200 > Commit: Laslo Hunhold > CommitDate: Thu Mar 30 08:43:42 2017 +0200 >

Re: [hackers] [farbfeld] Overhaul Build-system || Laslo Hunhold

2017-03-29 Thread Hiltjo Posthuma
On Wed, Mar 29, 2017 at 05:52:57PM +0200, g...@suckless.org wrote: > commit 416f39e3d68a6b12a05751930a609cfbbde483ff > Author: Laslo Hunhold > AuthorDate: Wed Mar 29 17:51:41 2017 +0200 > Commit: Laslo Hunhold > CommitDate: Wed Mar 29 17:51:41 2017 +0200 >

Re: Re: [hackers] [sbase][PATCH] Fixed a couple of uninitialised variable warnings from Clang

2017-02-07 Thread Hiltjo Posthuma
On Mon, Feb 06, 2017 at 02:04:52PM -0800, Evan Gates wrote: > Hiltjo Posthuma <hil...@codemadness.org> wrote: > > > Probably a false positive, but for ed.c it looks ok to me. > > > > The join.c patch does not look ok to me (clang doesn't detect that > > ep

Re: [hackers] [sbase][PATCH] Fixed a couple of uninitialised variable warnings from Clang

2017-02-02 Thread Hiltjo Posthuma
Probably a false positive, but for ed.c it looks ok to me. The join.c patch does not look ok to me (clang doesn't detect that eprintf() exists the program), so it's a false positive. On Thu, Feb 2, 2017 at 3:43 PM, Simon Cooksey wrote: > - ed.c >Initialise hline in

Re: [hackers] [sbase] ed: Don't use strlcpy() || Roberto E. Vargas Caballero

2017-01-10 Thread Hiltjo Posthuma
On Tue, Jan 10, 2017 at 08:56:46AM +0100, g...@suckless.org wrote: > commit b95c8ed79e5d5322dd3c5c386c3acd62105ac116 > Author: Roberto E. Vargas Caballero > AuthorDate: Tue Jan 10 08:46:48 2017 +0100 > Commit: Roberto E. Vargas Caballero

Re: [hackers] [dmenu][PATCH] Revert "fix input text matching"

2016-12-11 Thread Hiltjo Posthuma
On Wed, Dec 07, 2016 at 09:45:01AM -0500, Andrew Gregory wrote: > This reverts commit 09d0a36e0370f7ca9bdb171bf93c5ac3131c5a92. > > Using strncmp with the length of the user input turns it into a prefix > match rather than an exact match as it's supposed to be. > --- > dmenu.c | 2 +- > 1 file

Re: [hackers] [dwm] applied Ivan Delalande's NET_SUPPORTING_WM_CHECK patch for gtk3 compatibility || Anselm R Garbe

2016-12-05 Thread Hiltjo Posthuma
On Mon, Dec 05, 2016 at 01:51:36PM +0100, Silvan Jegen wrote: > On Mon, Dec 5, 2016 at 1:45 PM, Markus Teich > wrote: > > Anselm R Garbe wrote: > >> I agree, but my MUA couldn't detect a proper attachment. > > > > Heyho Anselm, > > > > `git am` also works with the

Re: [hackers] [sbase] [PATCH 05/10] tail: Use getc and putc instead of concat

2016-12-05 Thread Hiltjo Posthuma
On Sun, Dec 04, 2016 at 09:55:07PM -0800, Michael Forney wrote: > The FILE streams are buffered, so the end result is essentially the > same, except now lines are printed as they are read since we don't wait > until the entire buffer is filled. > > This also fixes an issue where only part of the

Re: [hackers] [sbase] [PATCH 09/10] tail: Use fstat in case file is removed

2016-12-05 Thread Hiltjo Posthuma
On Sun, Dec 04, 2016 at 09:55:11PM -0800, Michael Forney wrote: > --- > tail.c | 16 +++- > 1 file changed, 7 insertions(+), 9 deletions(-) > > diff --git a/tail.c b/tail.c > index ad97308..000be62 100644 > --- a/tail.c > +++ b/tail.c > @@ -133,7 +133,7 @@ main(int argc, char

Re: [hackers] [dwm] applied Ivan Delalande's NET_SUPPORTING_WM_CHECK patch for gtk3 compatibility || Anselm R Garbe

2016-12-05 Thread Hiltjo Posthuma
Hey Anselm, I think its better to use `git am` next time to apply the original patches. This way the original author, commit message/reason/explanation is archived aswell. -- Kind regards, Hiltjo

Re: [hackers] [dwm] [PATCH] support the NET_SUPPORTING_WM_CHECK EWMH property

2016-11-27 Thread Hiltjo Posthuma
On Sat, Nov 26, 2016 at 08:00:01AM +0100, Ivan Delalande wrote: > GTK3 checks for this property in some of its functions and simply give > up if it's not there and set correctly. This notably caused fullscreen > to be broken on recent versions of Firefox. > > This is mostly arg's 762b66a

Re: [hackers] [dwm] [PATCH] make OOM on new client non-fatal

2016-11-11 Thread Hiltjo Posthuma
On Fri, Nov 11, 2016 at 11:38 PM, Markus Teich wrote: >> >>> I can at least imagine cases where quitting on allocation failure is not >> >>> good. For example dwm is running, a new client starting up, but there is >> >>> no memory left for the client struct. In this

Re: [hackers] [libsl] die() on failure in ecalloc?

2016-11-05 Thread Hiltjo Posthuma
On Fri, Nov 04, 2016 at 07:53:35PM +0100, Markus Teich wrote: > Heyho Hiltjo, > > > > My proposal would be to change ecalloc to use die() and in the rare cases > > > where the allocation error should be handled gracefully just don't use > > > ecalloc, but calloc directly. > > > > > > Btw: The

Re: [hackers] [libsl] die() on failure in ecalloc?

2016-11-04 Thread Hiltjo Posthuma
On Thu, Nov 03, 2016 at 06:27:21PM +0100, Markus Teich wrote: > Heyho, > Hiya! > Davids patch for sent reminded me of an open issue. I proposed the following > change to libsls ecalloc() a few months ago, but did not get feedback. > > void * > ecalloc(size_t nmemb, size_t size)

Re: [hackers] [slock][PATCH] Improve option parsing routine

2016-10-29 Thread Hiltjo Posthuma
On Sat, Oct 29, 2016 at 12:11 PM, Ali H. Fardan <r...@firemail.cc> wrote: > On 2016-10-29 12:40, Hiltjo Posthuma wrote: >> >> This is total bullshit: it is less readable and it makes no sense to >> optimize this case. Please fix real bugs. > > > uhm,

Re: [hackers] [slock][PATCH] Improve option parsing routine

2016-10-29 Thread Hiltjo Posthuma
On Sat, Oct 29, 2016 at 12:32 AM, Klemens Nanni wrote: > This reduces the amount of strcmp() calls and comparisons in general to > a minimum. > --- > slock.c | 13 ++--- > 1 file changed, 6 insertions(+), 7 deletions(-) > > diff --git a/slock.c b/slock.c > index

Re: [hackers] [dwm] [PATCH] get rid of unnecessary ternary operator

2016-10-28 Thread Hiltjo Posthuma
On Thu, Oct 27, 2016 at 12:41:25PM +0200, Laslo Hunhold wrote: > On Thu, 27 Oct 2016 10:02:32 +0200 > Anselm R Garbe wrote: > > > To me ! is logical NOT and your suggestion relies on the fact that > > XUrgencyHint is a single bit flag? no? > > I prefer the original code, as it

Re: [hackers] [dmenu] Partial completion

2016-10-19 Thread Hiltjo Posthuma
On Wed, Oct 19, 2016 at 04:14:40PM +0200, Felix Van der Jeugt wrote: > Dear all, > > Attached patch changes behaviour of the Tab key for dmenu. Instead of > replacing the written text with the current selection, it replaces the > written text with the longest common prefix of all matches. > >

Re: [hackers] [sbase] [patch] cp: add -i flag

2016-10-09 Thread Hiltjo Posthuma
Two things I noticed: It does not seem to compile, it requires cp_iflag in fs.h: diff --git a/fs.h b/fs.h index 15ae5f4..36b9cb3 100644 --- a/fs.h +++ b/fs.h @@ -25,6 +25,7 @@ enum { extern int cp_aflag; extern int cp_fflag; +extern int cp_iflag; extern int cp_pflag; extern int cp_rflag;

Re: [hackers] [PATCH][sdhcp] Coding style and minor fixes

2016-09-26 Thread Hiltjo Posthuma
On Mon, Sep 26, 2016 at 10:26:41AM +0200, Ramsey wrote: > Hi list, > I don't like the extra braces for example: Good: if (1) ... vs "bad": if (1) { ... } Also goto's are perfectly fine in some cases. -- Kind regards, Hiltjo

Re: [hackers] Re: [ii] [GIGA-patchset] Hiltjo-branch

2016-09-25 Thread Hiltjo Posthuma
On Thu, Jun 23, 2016 at 10:47:09PM +0200, Nico Golde wrote: > * Hiltjo Posthuma <hil...@codemadness.org> [2016-05-10 01:14]: > > On Mon, May 9, 2016 at 7:52 PM, Nico Golde <n...@ngolde.de> wrote: > [...] > > > To be honest I was a little in shock when I saw thi

Re: [hackers] [surf/surf-webkit2] Add support for loading Webkit extensions || Quentin Rameau

2016-09-23 Thread Hiltjo Posthuma
On Thu, Sep 22, 2016 at 10:22:14AM +0200, g...@suckless.org wrote: > commit da5290a41aac4eabef83f6b88039f44d28b0ea00 > Author: Quentin Rameau > AuthorDate: Mon Nov 23 22:12:00 2015 +0100 > Commit: Quentin Rameau > CommitDate: Thu Sep 22 10:21:31 2016

Re: [hackers] [quark] Initial commit of quark rewrite || FRIGN

2016-09-02 Thread Hiltjo Posthuma
On Fri, Sep 02, 2016 at 12:37:00PM +0100, Nick wrote: > Hi FRIGN, > > I don't have time to look at this closely now, but one little thing > that jumped out at me: > > > +static const struct { > > + char *ext; > > + char *type; > > +} mimes[] = { > > ... > > Why are you defining the struct

Re: [hackers] [slock] CVE-2016-6866 NULL Pointer Dereference Denial of Service Vulnerability(2016-08-19)

2016-08-30 Thread Hiltjo Posthuma
Any more input on this from the community? (you, yes you behind the keyboard) -- Kind regards, Hiltjo

Re: [hackers] [slock] CVE-2016-6866 NULL Pointer Dereference Denial of Service Vulnerability(2016-08-19)

2016-08-22 Thread Hiltjo Posthuma
On Mon, Aug 22, 2016 at 03:15:07PM +0200, Markus Teich wrote: > Heyho, > > FRIGN pointed me to this[0] yesterday. > > > Vendor was notified about this issue on 2015-11-13. > > I could not find a mail related to this on the suckless mailing lists for that > date, but hiro mentioned an unspecific

Re: [hackers] [dmenu] [PATCH] Fix prefix match is treated as exact match

2016-08-21 Thread Hiltjo Posthuma
On Sat, Aug 20, 2016 at 11:26:50PM +0200, David Dufberg Tøttrup wrote: > > > From 10e65f4f8c1016ce90d6e0d159c78ca642d4bba3 Mon Sep 17 00:00:00 2001 > From: =?UTF-8?q?David=20Dufberg=20T=C3=B8ttrup?= > Date: Sat, 20 Aug 2016 16:20:19 +0200 > Subject: [PATCH] Fix prefix match is

Re: [hackers] [sic] add support for pledge()

2016-08-14 Thread Hiltjo Posthuma
On Sun, Aug 14, 2016 at 12:30:46AM +0200, Joerg Jung wrote: > Hi, > > please find below a diff for sic to enable pledge() to be used on > OpenBSD. This diff was originally submitted by Ali H. Fardan via > po...@openbsd.org. While here, I enabled the usage of strlcpy() > from libc on OpenBSD. >

Re: [hackers] [sent] Fix error-messages || FRIGN

2016-08-12 Thread Hiltjo Posthuma
On Fri, Aug 12, 2016 at 03:06:06PM +0200, Markus Teich wrote: > Heyho, > > Hiltjo Posthuma wrote: > > Here is a patch that improve the error messages a bit more and a patch that > > checks a memory allocation case. > > Thanks, I clarified the split error mess

Re: [hackers] [sent] Fix error-messages || FRIGN

2016-08-12 Thread Hiltjo Posthuma
On Fri, Aug 12, 2016 at 11:18:43AM +0200, Markus Teich wrote: > Hiltjo Posthuma wrote: > > I (and some others) think we should apply the behaviour change in die() to > > all > > other suckless projects that use it for consistency. > > Heyho, > > yes, I propo

Re: [hackers] [sent] Fix error-messages || FRIGN

2016-08-12 Thread Hiltjo Posthuma
On Fri, Aug 12, 2016 at 11:18:43AM +0200, Markus Teich wrote: > Hiltjo Posthuma wrote: > > I (and some others) think we should apply the behaviour change in die() to > > all > > other suckless projects that use it for consistency. > > Heyho, > > yes, I propo

Re: [hackers] [sent] Fix error-messages || FRIGN

2016-08-12 Thread Hiltjo Posthuma
I (and some others) think we should apply the behaviour change in die() to all other suckless projects that use it for consistency. -- Kind regards, Hiltjo

[hackers] Re: [slock][patch] clear passwords with explicit_bzero

2016-08-07 Thread Hiltjo Posthuma
Can someone apply this patch or give a reason why it sucks? :) -- Kind regards, Hiltjo

[hackers] [slock][patch] clear passwords with explicit_bzero

2016-07-31 Thread Hiltjo Posthuma
for the reminder. Let me know what you think or if i've missed something. Patch: >From d3f47bef10384ae624e5e7f81063e1bc1f37962c Mon Sep 17 00:00:00 2001 From: Hiltjo Posthuma <hil...@codemadness.org> Date: Sun, 31 Jul 2016 13:43:00 +0200 Subject: [PATCH] clear passwords with explicit_bz

Re: [hackers] [dmenu] Partially revert 44c7de3: fix items text width offset calculation

2016-07-25 Thread Hiltjo Posthuma
On Mon, Jul 25, 2016 at 11:33:25AM +0200, Quentin Rameau wrote: > Without this, we discard the item if it's longer than assigned width > instead of truncating it. > --- > dmenu.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/dmenu.c b/dmenu.c > index

Re: [hackers] [dmenu] import new drw from libsl and minor fixes.

2016-06-28 Thread Hiltjo Posthuma
On Sun, Jun 26, 2016 at 01:05:18PM -0700, Eric Pruitt wrote: > On Sun, Jun 26, 2016 at 02:53:03PM +0200, Hiltjo Posthuma wrote: > > I have pushed the drw changes to dmenu and dwm. > > > > Thanks for the contributions! > > > > It would be nice if people t

Re: [hackers] [dmenu] import new drw from libsl and minor fixes.

2016-06-26 Thread Hiltjo Posthuma
On Fri, Jun 03, 2016 at 09:12:11PM +0200, Markus Teich wrote: > Hiltjo Posthuma wrote: > > Fair enough, I think I'll apply it with the (temporary fix), since the > > current > > width is also less accurate and the speed trade-off is not worth it. > > > > Again:

Re: [hackers] [dmenu] [PATCHES] Improve code readability

2016-06-21 Thread Hiltjo Posthuma
Hi, I don't think it is an improvement, so will disregard it. -- Kind regards, Hiltjo

Re: [hackers] [dwm] [PATCH] Replace str[n]cpy with strlcpy

2016-06-07 Thread Hiltjo Posthuma
On Mon, Jun 06, 2016 at 08:50:31PM +0200, FRIGN wrote: > On Mon, 6 Jun 2016 20:12:19 +0200 > k...@shike2.com wrote: > >> ... > > Nope, it's not. Keep in mind strlcpy fills the rest > of the memory area with 0's. No it doesn't, but strncpy does that. > Also, I suspect you have not understood

Re: [hackers] [sent][patch] load slide image on-demand

2016-06-04 Thread Hiltjo Posthuma
On Sat, Jun 04, 2016 at 05:28:31PM +0200, Markus Teich wrote: > Hiltjo Posthuma wrote: > > previously an image file would be opened but only ffread when advancing to > > the slide, but when the slide was not used it gave an error: > > > > /usr/local/bin/2ff:

Re: [hackers] [dmenu] import new drw from libsl and minor fixes.

2016-06-03 Thread Hiltjo Posthuma
On Fri, Jun 03, 2016 at 07:42:37PM +0200, Markus Teich wrote: > Hiltjo Posthuma wrote: > > Your patch fixes the slowness for me, but we need to think of a more > > accurate > > but faster way indeed. > > Heyho, > > I plan to clean up the drw_text function

Re: [hackers] [dmenu] import new drw from libsl and minor fixes.

2016-06-03 Thread Hiltjo Posthuma
On Fri, Jun 03, 2016 at 06:55:36PM +0200, Markus Teich wrote: > Hiltjo Posthuma wrote: > > I noticed a regression, dmenu seems really slow to load on my machine in the > > function readstdin(). Was the font cache behaviour removed from drw? > > Heyho, > Heya!, &g

Re: [hackers] [dwm] [PATCH] Replace str[n]cpy with strlcpy

2016-06-03 Thread Hiltjo Posthuma
On Thu, Jun 02, 2016 at 09:57:01PM +0200, FRIGN wrote: > Hello fellow hackers, > > I'll drop this little patch here so we finally make the switch to the > safe OpenBSD-functions for string copying. A good compromise might be using snprintf(buf, sizeof(buf), "%s", text) this is standard and

Re: [hackers] [dmenu] import new drw from libsl and minor fixes.

2016-06-03 Thread Hiltjo Posthuma
On Sun, May 22, 2016 at 10:34:30PM +0200, Markus Teich wrote: > - extract drawitem function (code deduplication) > - fix bug where inputw was not correctly calculated from the widest item, but > just from the one with the longest strlen() which is not the same. > - minor code style fixes

Re: [hackers] [PATCH 4/8] drw: simplify color schemes

2016-05-23 Thread Hiltjo Posthuma
On Mon, May 23, 2016 at 07:40:14PM +0200, Markus Teich wrote: > Hiltjo Posthuma wrote: > > I'm willing to apply your unification patches to dmenu and dwm, but can you > > make a patch for dwm/dmenu if it breaks it? > > Heyho Hiltjo, > > sorry, I don't quite

Re: [hackers] [scc] Implement proper #pragma support || sin

2016-05-12 Thread Hiltjo Posthuma
On Thu, May 12, 2016 at 7:29 PM, wrote: > commit c9cccba538e9870b1177ae4c57dad716e9f02185 > Author: sin > AuthorDate: Wed May 11 17:38:15 2016 +0100 > Commit: Roberto E. Vargas Caballero > CommitDate: Wed May 11 17:35:52 2016 +0200 > > Implement

Re: [hackers] Re: [ii] [GIGA-patchset] Hiltjo-branch

2016-05-09 Thread Hiltjo Posthuma
On Mon, May 9, 2016 at 7:52 PM, Nico Golde wrote: > Hi, > > This is massive, pretty exciting! > Hi and thanks! It came as a bit of a surprise to me too, but it is nice FRIGN posted it. There can be some silly commits though since it is an incremental patchset, so the changeset

[hackers] [scc] fix test001, uninitialized value after include

2016-05-06 Thread Hiltjo Posthuma
>From 9d83c63ab6557d1a7effbcb6c88cac00bc507ef2 Mon Sep 17 00:00:00 2001 From: Hiltjo Posthuma <hil...@codemadness.org> Date: Fri, 6 May 2016 22:18:53 +0200 Subject: [PATCH] fix uninitialized value after include(), fixes test001 The issue manifests after the line "#inclu

Re: [hackers] [ubase][PATCH] hwclock: [-rsw] => (-r | -s | -w) and fix flag check

2016-04-22 Thread Hiltjo Posthuma
On Fri, Apr 22, 2016 at 03:24:47AM +0200, Mattias Andrée wrote: > Also in man page: [-r | -s | -w] => (-r | -s | -w) > > 8< ... snippity snip ...>8 > > int > @@ -141,7 +141,7 @@ main(int argc, char *argv[]) > else if (argc == 1) > dev = argv[0]; > > - if ((rflag ^

Re: [hackers][farbfeld][patch] ffcrop tool.

2016-04-08 Thread Hiltjo Posthuma
On Fri, Apr 08, 2016 at 01:13:09PM +, ra...@openmailbox.org wrote: > This adds a crop tool to farbfeld, the use is: ffcrop x y w h. > > What do you think? Cool idea, I think farbfeld should have some useful tools included, maybe in a separate tools/ directory or something. Another tool I

Re: [hackers] [ubase][PATCH v2] Add pwdx(1)

2016-03-26 Thread Hiltjo Posthuma
On Sat, Mar 26, 2016 at 12:58:37PM +0100, Mattias Andr??e wrote: > + > + for (; argc > 0; argc--, argv++) { > + n = snprintf(path, sizeof(path), "/proc/%s/cwd", *argv); > + if (n < 0 || n > sizeof(path)) { > + errno = ESRCH; The line: > +

Re: [hackers] [ubase][PATCH] Add pwdx(1)

2016-03-26 Thread Hiltjo Posthuma
On Sat, Mar 26, 2016 at 12:30:50AM +0100, Mattias Andr??e wrote: > Signed-off-by: Mattias Andr??e > diff --git a/pwdx.c b/pwdx.c > new file mode 100644 > index 000..b9836b7 > --- /dev/null > +++ b/pwdx.c > @@ -0,0 +1,53 @@ > +/* See LICENSE file for copyright and license

Re: [hackers] dmenu][PATCH reversed

2016-02-21 Thread Hiltjo Posthuma
On Sat, Feb 20, 2016 at 10:28 PM, Maurycy Skier wrote: > Hi, I hope I am doing everything right. > > I added a new option (-r) which reverses the list and puts the input under > it. If you've used Vimperator or CtrlP plugin in Vim you can say it tries to > make dmenu lookalike

Re: [hackers][sbase][PATCH] arg.h: fixed argv checks order

2016-02-19 Thread Hiltjo Posthuma
On Fri, Feb 19, 2016 at 8:43 PM, Lucas Gabriel Vuotto wrote: > this is a small fix for arg.h where it's possible to perform an > out-of-boundary memory access in argv's internal string. In particular, this > is a fix for sbase's arg.h, but I've also seen it in st repo, and I

Re: [hackers] [dmenu] Typofix, patches rebased

2016-01-11 Thread Hiltjo Posthuma
On Mon, Jan 11, 2016 at 6:29 PM, Klemens Nanni wrote: > Hey, > Hi! > cc596365a (unbolify dmenu) "breaks" some of the patches provided at > tools.suckless.org/dmenu/patches. Basically 's,bool,int' was all I had > to do besides some offset correction. Since this is the first

Re: [hackers] [dmenu][RFC][PATCH 0/4] Using sort and simple C program to get dmenu history functionality

2015-11-30 Thread Hiltjo Posthuma
On Mon, Nov 30, 2015 at 3:28 PM, Silvan Jegen <s.je...@gmail.com> wrote: > Heyho! > > On Sat, Nov 28, 2015 at 11:25 PM, Hiltjo Posthuma > <hil...@codemadness.org> wrote: >> On Fri, Nov 27, 2015 at 7:38 PM, Silvan Jegen <s.je...@gmail.com> wrote: >> This

Re: [hackers] [dmenu][RFC][PATCH 0/4] Using sort and simple C program to get dmenu history functionality

2015-11-28 Thread Hiltjo Posthuma
On Fri, Nov 27, 2015 at 7:38 PM, Silvan Jegen wrote: > Heyhey > > I kept thinking about a more general way to implement history > functionality for dmenu and this is what I came up with. > > We use the sort command to generate an input list for dmenu sorted by > count (first

Re: [hackers] [sent] drw.c: Avoid potential memory leak in drw_cur_create()

2015-11-21 Thread Hiltjo Posthuma
On Wed, Nov 18, 2015 at 10:54 PM, Markus Teich wrote: > The drw code of sent diverged from the drw code of dmenu/dwm/… a couple of > months ago. I submitted my changes earlier this year, they were never merged > into upstream libdrw. Now we have two different histories

Re: [hackers] [dmenu] Command History Patch

2015-11-20 Thread Hiltjo Posthuma
On Fri, Nov 20, 2015 at 7:04 AM, Stephen Sherratt wrote: > I made a patch to add suggestions to dmenu based on previously run commands. > I know there already exists such a patch > (http://tools.suckless.org/dmenu/patches/history) but it seems to be quite > old and doesn't work

Re: [hackers] [dmenu] Fix incorrect ordering of matching results

2015-10-04 Thread Hiltjo Posthuma
On Fri, Aug 14, 2015 at 6:28 PM, Davide Del Zompo wrote: > dmenu incorrectly orders matching results: > > $ dmenu < suck xless > suck less > EOF > > Typing 'suck less' shows 'suck xless' as first result, however, according to a > comment in the source code, this is not

Re: [hackers] [dmenu] paste fix

2015-10-04 Thread Hiltjo Posthuma
On Sat, Oct 3, 2015 at 3:09 AM, shua lloret wrote: > attached is a small patch to enable pasting from clipboard, as well as > primary. > > It seems like there was already code in there to allow this, but since there > was never any case to match the upper case 'Y', that

<    1   2   3   4   5   >