On Dec 15, 2004, at 6:44 PM, Alex Tweedly wrote:

So would you do something like
put "d:" & cr & "cd \My folder\my directory" & cr & "dir *.jpg" & cr into URL "my.bat"
put shell("cmd < my.bat")
delete file "my.bat"

Yeah, something like that.

But I'd like to hear any more you remember about problems with open process on Windows.

OK. Off the top of my head:

If you read too soon and there is no data, Rev will hang.

A control-. in a read will sometimes cause a crash.

Under some conditions processes are left running and unable to shut down, even ones that work on the command line such as ping. They have to be killed.

The 'in time' does not work right; the time is random.

Binary I/O is butchered.

until end will crash, but until empty will get what's in the buffer sometimes.

The read returns eof on an empty buffer and will throw an error near the end of data in a closed pipe.

Severe limitations: close will not only close the pipe to the process but will disable the ability to read the response. Also, if the process quits it is hard to read its last words.

Doc doesn't mention binary for open process or the difference between empty and end in open process

There are others, but I don't remember.

For most of these I found workarounds. There were some limitations that blocked what I was doing at the time and since RunRev seemed to have no desire to fix these, I gave up on open process. Anything with a dozen bugs like this is bound to have more; it did not seem prudent to go on. My customer had already decided I had gone off my rocker in doing this with Revolution.

These are from over two years ago, so some of these may have gotten fixed as other bugs were fixed.

The shell() is much more stable and can get data from a process that quits. Unfortunately, it tries to do line-end transformations on binary data. There is probably a base64 utility that can help with that.

The last time I check 'open process' on OS X, it didn't work at all.

Dar Scott
****************************************
    DSC
    http://www.swcp.com/dsc/
    Programming Services and Software
****************************************

_______________________________________________
use-revolution mailing list
[EMAIL PROTECTED]
http://lists.runrev.com/mailman/listinfo/use-revolution

Reply via email to