Displaying 2 results from an estimated 2 matches for "ngoodbye".
Did you mean:
goodbye
2002 Nov 22
2
Need help with pipe()
...data
frame with read.table().
I've recently upgraded from Win98SE to WinXP, and have also upgraded
from R1.5.0 to R1.6.1 over the past month or so. This program worked
before the upgrade(s), but now fails. I observe the following sort of
behavior with R1.6.1 under WinXP:
> cat("hello\ngoodbye\n",file="textfile")
> readLines("textfile")
[1] "hello" "goodbye"
> readLines(pipe("gawk '{print $0}' textfile"))
character(0)
# Note: R pauses for about 10 seconds before returning "character(0)"
> readLines(pipe(...
2011 Jan 06
1
[PATCH] close client socket after closing response body
...heck_stderr
+}
+
+t_done
diff --git a/t/write-on-close.ru b/t/write-on-close.ru
new file mode 100644
index 0000000..54a2f2e
--- /dev/null
+++ b/t/write-on-close.ru
@@ -0,0 +1,11 @@
+class WriteOnClose
+ def each(&block)
+ @callback = block
+ end
+
+ def close
+ @callback.call "7\r\nGoodbye\r\n0\r\n\r\n"
+ end
+end
+use Rack::ContentType, "text/plain"
+run(lambda { |_| [ 200, [%w(Transfer-Encoding chunked)], WriteOnClose.new ] })
--
Eric Wong