netwerk/base/src/nsSimpleStreamListener.h
author Benoit Jacob <bjacob@mozilla.com>
Tue, 24 Jun 2014 12:36:44 -0400
changeset 190540 ef6cb0f76224810fdaf44cd4c5164ff552e0ade0
parent 94475 f4157e8c410708d76703f19e4dfb61859bfe32d8
permissions -rw-r--r--
Bug 1028588 - Fix dangerous public destructors in netwerk/ - r=mcmanus

/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */

#include "nsISimpleStreamListener.h"
#include "nsIOutputStream.h"
#include "nsCOMPtr.h"

class nsSimpleStreamListener : public nsISimpleStreamListener
{
public:
    NS_DECL_ISUPPORTS
    NS_DECL_NSIREQUESTOBSERVER
    NS_DECL_NSISTREAMLISTENER
    NS_DECL_NSISIMPLESTREAMLISTENER

    nsSimpleStreamListener() { }

protected:
    virtual ~nsSimpleStreamListener() {}

    nsCOMPtr<nsIOutputStream>    mSink;
    nsCOMPtr<nsIRequestObserver> mObserver;
};