From removed Fri May 9 22:45:21 2014 From: removed (removed) Date: Fri, 09 May 2014 20:45:21 +0000 Subject: removed Message-ID: <1D.39.23675.38E3D635@mail02> removed From me at the-compiler.org Tue May 20 18:44:05 2014 From: me at the-compiler.org (Florian Bruhin) Date: Tue, 20 May 2014 18:44:05 +0200 Subject: [PATCH] Disallow empty tag name as target for rename. Message-ID: <20140520164405.GE13636@lupin> Using hc rename default '' or similiar it was possible to create an empty tag which should be prevented, the attached patch fixes this. -- () ascii ribbon campaign - stop html mail www.asciiribbon.org /\ www.the-compiler.org | I love long mails http://email.is-not-s.ms/ When the bosses talk about improving productivity, they are never talking about themselves. -------------- next part -------------- A non-text attachment was scrubbed... Name: 0001-Disallow-empty-tag-name-as-target-for-rename.patch Type: text/x-diff Size: 819 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 836 bytes Desc: not available URL: From me at the-compiler.org Tue May 20 18:45:14 2014 From: me at the-compiler.org (Florian Bruhin) Date: Tue, 20 May 2014 18:45:14 +0200 Subject: [PATCH] Add id objects for tags. In-Reply-To: <20140421164659.GA21018@lupin> References: <20140421164659.GA21018@lupin> Message-ID: <20140520164514.GF13636@lupin> * Florian Bruhin [2014-04-21 18:46:59 +0200]: > is there way to get tag name by id, easier than parsing tag_status ? > heh, why does the tags object only have a by-name, and no by-id? :P > if it had, it'd be easy \o/ > > And so this was born. Any update on this so far? :) If there's an issue which prevents this of being merged let me know, then I'll gladly take another look at it. Flo -- () ascii ribbon campaign - stop html mail www.asciiribbon.org /\ www.the-compiler.org | I love long mails http://email.is-not-s.ms/ "Can't you just gesture hypnotically and make him disappear?" "It does not work that way. RUN!" -- Hadji on metaphyics and Mandrake in "Johnny Quest" -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 836 bytes Desc: not available URL: From edu at thorsten-wissmann.de Tue May 20 22:22:52 2014 From: edu at thorsten-wissmann.de (Thorsten =?iso-8859-1?Q?Wi=DFmann?=) Date: Tue, 20 May 2014 22:22:52 +0200 Subject: [PATCH] Add id objects for tags. In-Reply-To: <20140520164514.GF13636@lupin> References: <20140421164659.GA21018@lupin> <20140520164514.GF13636@lupin> Message-ID: <20140520202252.GA14305@hoth.roethelheim.stw.uni-erlangen.de> On Tue, May 20, 2014 at 06:45:14PM +0200, Florian Bruhin wrote: > * Florian Bruhin [2014-04-21 18:46:59 +0200]: > > is there way to get tag name by id, easier than parsing tag_status ? > > heh, why does the tags object only have a by-name, and no by-id? :P > > if it had, it'd be easy \o/ > > > > And so this was born. > > Any update on this so far? :) > > If there's an issue which prevents this of being merged let me know, > then I'll gladly take another look at it. Just merged it (and added documentation) after testing it. Sorry for the delay. If you're waiting that long the next time, just kick me earlier. 4ad79cc Add tag id objects. Cheers, Thorsten -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 230 bytes Desc: not available URL: From edu at thorsten-wissmann.de Tue May 20 22:25:01 2014 From: edu at thorsten-wissmann.de (Thorsten =?iso-8859-1?Q?Wi=DFmann?=) Date: Tue, 20 May 2014 22:25:01 +0200 Subject: [PATCH] Disallow empty tag name as target for rename. In-Reply-To: <20140520164405.GE13636@lupin> References: <20140520164405.GE13636@lupin> Message-ID: <20140520202501.GB14305@hoth.roethelheim.stw.uni-erlangen.de> On Tue, May 20, 2014 at 06:44:05PM +0200, Florian Bruhin wrote: > Using hc rename default '' or similiar it was possible to create an > empty tag which should be prevented, the attached patch fixes this. Looked at the mail. Can merge&push without any testing :) f86edbf Disallow empty tag name as target for rename. Cheers, Thorsten > @@ -272,6 +272,11 @@ int tag_rename_command(int argc, char** argv, GString* output) { > if (argc < 3) { > return HERBST_NEED_MORE_ARGS; > } > + if (!strcmp("", argv[2])) { > + g_string_append_printf(output, > + "%s: An empty tag name is not permitted\n", argv[0]); > + return HERBST_INVALID_ARGUMENT; > + } > HSTag* tag = find_tag(argv[1]); > if (!tag) { > g_string_append_printf(output, -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 230 bytes Desc: not available URL: