Re: Problems with syscall <async>
"Ger Hobbelt" <[email protected]>
| Newsgroups | gmane.mail.spam.crm114 |
|---|---|
| Message-ID | <[email protected]> |
On Fri, Jul 18, 2008 at 2:26 PM, Bill Yerazunis <[email protected]> wrote: > (and here I was, fixing a little syntax gotcha in "isolate" and > "syscall". The issue was that > > syscall / \/etc\/usr\/local\/bin\/blah/ > > is highly error prone; the callee isn't even really a pattern, so > the new version allows boxes as well as slashes for the thing to run: > > syscall [ /etc/usr/local/bin/blah ] ( :my_input: ) ( :my_output:) > > This will be up soonish; the old format with slashes is still allowed. Ah, looks good (a welcome deviation for the standard purpose of the [] brackets, but what's a man to do?). BTW: I had a scripted 'fix' for this in a my extra test scripts: basically it's indirect use of the [..] brackets. See copy of test script below: track the construction of the :crm_exe: variable. The @-delimited items in there are set by the ./configure script - which doesn't do extra '/' escaping when substituting path variables. Tested with GerH crm114, which validates script statements more stringently, so commented-out items may or may not work on vanilla crm114. Test script showing 'old way': ---------------------------------- #! @abs_top_builddir@/src/crm114 # # See extra warnings at the bottom of this script # window { isolate (:count:) /10000/ isolate (:crm_exe:) // # translate () [text] // // --> error report (good work, but not really what I was looking for right now. # translate (:crm_exe:) [@abs_top_builddir@/src/crm114] // // # and another error for this one: # match (:crm_exe:) [@abs_top_builddir@/src/crm114] /.*/ # so we end up with the Final Solution - which is a wicked hack call /:cvt:/ (:crm_exe:) [@abs_top_builddir@/src/crm114] output /\n ----- running :*:count: syscalls (:*:crm_exe:) to see the timing -----\n/ { syscall /:*:crm_exe: '-{ window; }'/ eval (:count:) /:@::*:count:-1:/ # output / :*:count: / # output /./ eval /:@::*:count:>0:/ liaf; } output /\n ----- done -----\n/ exit /0/; } # # as the QUICKREF says: variables are expanded and concatenated in call [...] # and fed into this label (:arg:). Yay! EXACTLY what we need for unescaped-/ # challenged file paths! # :cvt: (:tmp:) { return /:*:tmp:/; } # # ============================================================================ ---------------------------------- -- Met vriendelijke groeten / Best regards, Ger Hobbelt -------------------------------------------------- web: http://www.hobbelt.com/ http://www.hebbut.net/ mail: [email protected] mobile: +31-6-11 120 978 -------------------------------------------------- ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/