From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from resqmta-po-04v.sys.comcast.net (resqmta-po-04v.sys.comcast.net [IPv6:2001:558:fe16:19:96:114:154:163]) by hurricane.the-brannons.com (Postfix) with ESMTPS id B337677CD1 for ; Sun, 28 Dec 2014 13:47:49 -0800 (PST) Received: from resomta-po-01v.sys.comcast.net ([96.114.154.225]) by resqmta-po-04v.sys.comcast.net with comcast id Z9lK1p0024s37d4019lbHY; Sun, 28 Dec 2014 21:45:35 +0000 Received: from eklhad ([68.84.191.77]) by resomta-po-01v.sys.comcast.net with comcast id Z9la1p00G1gep30019laxp; Sun, 28 Dec 2014 21:45:35 +0000 To: Edbrowse-dev@lists.the-brannons.com From: Karl Dahlke Reply-to: Karl Dahlke User-Agent: edbrowse/3.5.2 Date: Sun, 28 Dec 2014 16:45:34 -0500 Message-ID: <20141128164534.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=1419803135; bh=xLq4hCiYsoyScrfBP/Qlh0pD+fekK+Jrq4jLefIfNq4=; h=Received:Received:To:From:Reply-to:Subject:Date:Message-ID: Mime-Version:Content-Type; b=Wew+ClAZum4DUh1aRMtD+TA/B58FdzVVxTyJ5vCYq5MHBscs1xqI2KfKTWiSU1BVG +7/cnI+dyCIGs7eQJzMNgJSN1ULgpAY1J6xP/MtY7sYL1xKguArFIbB9fDBQ44DG3j dwz86hz9w8XU7fAUdmsDHdQFhAhmmovz43Uu9kqTDfBfFTDPPE8wAYfnc9rJCfFFSz JoFtkqTd9alAbBAdkwW3C4B5jf1dfHcjsPnZywSM0sT5z7qjVGfi6ez+Kx9hYwvGya 7shXVEL1GocpR/rWGUL9lHEyYJgMPvFAyInw7Z9uVmlKWOgByJQUm4E1QMUBnZF//z Idsj2mCLHOzvA== Subject: [Edbrowse-dev] wordexp 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: Sun, 28 Dec 2014 21:47:50 -0000 After some playing around with wordexp, I'm inclined to leave things alone. wordexp just does too much. Unbalanced parens or brackets or quotes or apostrophes will produce a syntax error. Here's a filename with one apostrophe in it. #include #include main() { wordexp_t w; int rc; rc = wordexp("isn't", &w, 0); if(rc == WRDE_SYNTAX) puts("syntax error"); } And even if the quotes are balanced, they will be taken away from you. #include #include main() { wordexp_t w; int rc; rc = wordexp("is'n't", &w, 0); puts(w.we_wordv[0]); } So many side effects that I'm sure people will be confused. I already wrote the code and it's been working for years, guess I'll leave it alone. Karl Dahlke