Add batons to svn_stream_t's line-filter and line-transformer callbacks,
because every callback should take a baton.

* subversion/include/svn_io.h
  (svn_io_line_filter_cb_t, svn_io_line_transformer_cb_t): Add a 'baton'
    argument.

* subversion/libsvn_diff/parse-diff.c
  (original_line_filter, modified_line_filter): Add a 'baton' argument (but
    don't use it).

* subversion/libsvn_subr/stream.c
  (line_filter, line_transformer): Pass the stream's baton to the callback.

* subversion/tests/libsvn_subr/stream-test.c
  (line_filter, line_transformer): Add a 'baton' argument (but don't use it).

--This line, and those below, will be ignored--

Index: subversion/include/svn_io.h
===================================================================
--- subversion/include/svn_io.h	(revision 38979)
+++ subversion/include/svn_io.h	(working copy)
@@ -699,12 +699,14 @@ typedef svn_error_t *(*svn_close_fn_t)(v
 typedef svn_error_t *(*svn_io_reset_fn_t)(void *baton);
 
 /** Line-filtering callback function for a generic stream.
- * @see svn_stream_t and svn_stream_readline().
+ * @a baton is the stream's baton.
+ * @see svn_stream_t, svn_stream_set_baton() and svn_stream_readline().
  *
  * @since New in 1.7.
  */
 typedef svn_error_t *(*svn_io_line_filter_cb_t)(svn_boolean_t *filtered,
                                                 const char *line,
+                                                void *baton,
                                                 apr_pool_t *scratch_pool);
 
 /** A callback function, invoked by svn_stream_readline(), which can perform
@@ -718,12 +720,16 @@ typedef svn_error_t *(*svn_io_line_filte
  * Implementations should always at least return an empty stringbuf.
  * It is a fatal error if an implementation returns @a *buf as NULL.
  *
- * @see svn_stream_t, svn_io_line_filter_cb_t and svn_stream_readline().
- * 
+ * @a baton is the stream's baton.
+ *
+ * @see svn_stream_t, svn_stream_set_baton(), svn_io_line_filter_cb_t and
+ * svn_stream_readline().
+ *
  * @since New in 1.7.
  */
 typedef svn_error_t *(*svn_io_line_transformer_cb_t)(svn_stringbuf_t **buf,
                                                      const char *line,
+                                                     void *baton,
                                                      apr_pool_t *result_pool,
                                                      apr_pool_t *scratch_pool);
 
Index: subversion/libsvn_diff/parse-diff.c
===================================================================
--- subversion/libsvn_diff/parse-diff.c	(revision 38979)
+++ subversion/libsvn_diff/parse-diff.c	(working copy)
@@ -275,7 +275,7 @@ parse_hunk_header(const char *header, sv
 
 /* A stream line-filter which allows only original text from a hunk. */
 static svn_error_t *
-original_line_filter(svn_boolean_t *filtered, const char *line,
+original_line_filter(svn_boolean_t *filtered, const char *line, void *baton,
                      apr_pool_t *scratch_pool)
 {
   *filtered = line[0] == '+';
@@ -284,7 +284,7 @@ original_line_filter(svn_boolean_t *filt
 
 /* A stream line-filter which allows only modified text from a hunk. */
 static svn_error_t *
-modified_line_filter(svn_boolean_t *filtered, const char *line,
+modified_line_filter(svn_boolean_t *filtered, const char *line, void *baton,
                      apr_pool_t *scratch_pool)
 {
   *filtered = line[0] == '-';
Index: subversion/libsvn_subr/stream.c
===================================================================
--- subversion/libsvn_subr/stream.c	(revision 38979)
+++ subversion/libsvn_subr/stream.c	(working copy)
@@ -216,7 +216,7 @@ line_filter(svn_stream_t *stream, svn_bo
     }
 
   scratch_pool = svn_pool_create(pool);
-  SVN_ERR(stream->line_filter_cb(filtered, line, scratch_pool));
+  SVN_ERR(stream->line_filter_cb(filtered, line, stream->baton, scratch_pool));
   svn_pool_destroy(scratch_pool);
   return SVN_NO_ERROR;
 }
@@ -229,7 +229,8 @@ line_transformer(svn_stream_t *stream, s
                  const char *line, apr_pool_t *pool, apr_pool_t *scratch_pool)
 {
   *buf = NULL;  /* so we can assert that the callback has set it non-null */
-  SVN_ERR(stream->line_transformer_cb(buf, line, pool, scratch_pool));
+  SVN_ERR(stream->line_transformer_cb(buf, line, stream->baton,
+                                      pool, scratch_pool));
 
   /* Die if the line transformer didn't provide any output. */
   SVN_ERR_ASSERT(*buf);
Index: subversion/tests/libsvn_subr/stream-test.c
===================================================================
--- subversion/tests/libsvn_subr/stream-test.c	(revision 38979)
+++ subversion/tests/libsvn_subr/stream-test.c	(working copy)
@@ -309,7 +309,8 @@ test_stream_range(apr_pool_t *pool)
 
 /* An implementation of svn_io_line_filter_cb_t */
 static svn_error_t *
-line_filter(svn_boolean_t *filtered, const char *line, apr_pool_t *scratch_pool)
+line_filter(svn_boolean_t *filtered, const char *line, void *baton,
+            apr_pool_t *scratch_pool)
 {
   *filtered = strchr(line, '!') != NULL;
   return SVN_NO_ERROR;
@@ -347,7 +348,7 @@ test_stream_line_filter(apr_pool_t *pool
 
 /* An implementation of svn_io_line_transformer_cb_t */
 static svn_error_t *
-line_transformer(svn_stringbuf_t **buf, const char *line,
+line_transformer(svn_stringbuf_t **buf, const char *line, void *baton,
                  apr_pool_t *result_pool, apr_pool_t *scratch_pool)
 {
   int i, len = strlen(line);

