<commit_before>package hudson.util;

import hudson.Util;

import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;

/**
 * {@link Thread} that copies {@link InputStream} to {@link OutputStream}.
 *
 * @author <NAME>
 */
public class StreamCopyThread extends Thread {
    private final InputStream in;
    private final OutputStream out;

    public StreamCopyThread(String threadName, InputStream in, OutputStream out) {
        super(threadName);
        this.in = in;
        this.out = out;
    }

    public void run() {
        try {
            try {
                Util.copyStream(in,out);
            } finally {
                in.close();
            }
        } catch (IOException e) {
            // TODO: what to do?
        }
    }
}<commit_msg>relying on Util.copyStream causes unnecessary dependency to Ant class used in the Util class (#802)<commit_after>package hudson.util;

import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;

/**
 * {@link Thread} that copies {@link InputStream} to {@link OutputStream}.
 *
 * @author <NAME>
 */
public class StreamCopyThread extends Thread {
    private final InputStream in;
    private final OutputStream out;

    public StreamCopyThread(String threadName, InputStream in, OutputStream out) {
        super(threadName);
        this.in = in;
        this.out = out;
    }

    public void run() {
        try {
            try {
                byte[] buf = new byte[8192];
                int len;
                while ((len = in.read(buf)) > 0)
                    out.write(buf, 0, len);
            } finally {
                in.close();
            }
        } catch (IOException e) {
            // TODO: what to do?
        }
    }
}
{'fraction_non_alphanumeric': 0.10493477027793534, 'fraction_numerical': 0.005104934770277935, 'mean_word_length': 1.94, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 6, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5623462', 'n_tokens_mistral': 501, 'n_tokens_neox': 477, 'n_words': 146}