From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from resqmta-ch2-12v.sys.comcast.net (resqmta-ch2-12v.sys.comcast.net [IPv6:2001:558:fe21:29:69:252:207:44]) by hurricane.the-brannons.com (Postfix) with ESMTPS id 927F17AE85 for ; Thu, 16 Apr 2015 14:41:57 -0700 (PDT) Received: from resomta-ch2-01v.sys.comcast.net ([69.252.207.97]) by resqmta-ch2-12v.sys.comcast.net with comcast id GlgN1q00A26dK1R01lgudb; Thu, 16 Apr 2015 21:40:54 +0000 Received: from eklhad ([IPv6:2601:4:5380:4ee:21e:4fff:fec2:a0f1]) by resomta-ch2-01v.sys.comcast.net with comcast id Glgu1q0015LMg2101lgucG; Thu, 16 Apr 2015 21:40:54 +0000 To: Edbrowse-dev@lists.the-brannons.com From: Karl Dahlke Reply-to: Karl Dahlke User-Agent: edbrowse/3.5.3+ Date: Thu, 16 Apr 2015 17:40:53 -0400 Message-ID: <20150316174053.eklhad@comcast.net> Mime-Version: 1.0 Content-Type: text/plain Content-Transfer-Encoding: 7bit DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=comcast.net; s=q20140121; t=1429220454; bh=k+SxdjhBNBeUN6iyLfoIK3r1UshfvQ6XHgzJYMW/oxA=; h=Received:Received:To:From:Reply-to:Subject:Date:Message-ID: Mime-Version:Content-Type; b=W+Gea46dyE994fBZvg50nSVnm4bxtu7JW5eqwfudtNRccrbLQjJU7Ytn65j3r8MOA 7WJz9wjYPMSbcr/PO7RqjzprYo5dNeQFHG5BHKBJlDAnRp0GfwjJyZiWvTUseMRMSW r8VBPwC+FKZWU07IxZfi7dt1YDc9ow7p8Vk/u9VVzZF0Cm7y0uxvUmgLBADoVuLFq5 bLB8psZnyjY1Q+a3JPCsJd3/TaF7H7btdDbmWeolXE/WCsAiHZvu2tsUoalSdcV9+2 kznEqB89LUbNePa5KeMmHyxN9JOkB/h0uON73ePuG4lZXebHFQkOvCeY3mrnYLwSv1 bAwb/CjR2rFAg== Subject: [Edbrowse-dev] wordexp again X-BeenThere: edbrowse-dev@lists.the-brannons.com X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Edbrowse Development List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Apr 2015 21:41:57 -0000 I made one common routine to protect a file name or directory name from shell expansion, it's the same code I was using before, but now it is shared between the directory scan and the plugin commands. Ok, that's good software practice, but it exposed a bug that I think was there all along. You can't edit a directory with a backslash in it. mkdir "a\\b" cd a?b touch foo bar cd .. edbrowse a?b Try it before or after my latest push. The files therein just don't show up, because wordexp doesn't expand a\\b/* properly. and that is the proper escaping. At the shell prompt ls a\\b/* works fine. And it all works through the plugin system, i.e. a\b.pdf becomes pdftohtml a\\b.pdf This seems to be a bug in wordexp, at least my wordexp, and I'm really not sure what to do about it. Karl Dahlke