#vulnerable code 
                                @Deprecated
    public void executeShell(OutputStream output, String command, String... args) throws IOException, JadbException {
        Transport transport = getTransport();
        StringBuilder shellLine = new StringBuilder(command);
        for (String arg : args) {
            shellLine.append(" ");
            shellLine.append(Bash.quote(arg));
        }
        send(transport, "shell:" + shellLine.toString());
        if (output != null) {
            transport.readResponseTo(new AdbFilterOutputStream(output));
        }
    } 
                            #location 11 
                            #vulnerability type RESOURCE_LEAK
#fixed code
                                @Deprecated
    public void executeShell(OutputStream output, String command, String... args) throws IOException, JadbException {
        Transport transport = getTransport();
        StringBuilder shellLine = new StringBuilder(command);
        for (String arg : args) {
            shellLine.append(" ");
            shellLine.append(Bash.quote(arg));
        }
        send(transport, "shell:" + shellLine.toString());
        if (output != null) {
        	AdbFilterOutputStream out = new AdbFilterOutputStream(output);
        	try {
        		transport.readResponseTo(out);
        	} finally {
        		out.close();
        	}
        }
    }