summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichele Calgaro <michele.calgaro@yahoo.it>2024-01-18 00:12:55 +0900
committerMichele Calgaro <michele.calgaro@yahoo.it>2024-01-18 12:12:58 +0900
commitb117d960b83d41e97c88dbfd0796a06ff1447e29 (patch)
treea97b06718d27038b46ab2ed2de5c2819001c787a
parenteeecdda1a3987158b7a9c3016c63dbc72347fe90 (diff)
downloadtdeio-apt-b117d960b83d41e97c88dbfd0796a06ff1447e29.tar.gz
tdeio-apt-b117d960b83d41e97c88dbfd0796a06ff1447e29.zip
Replace auto_ptr
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
-rw-r--r--src/apt.cpp4
-rw-r--r--src/apt.h2
2 files changed, 3 insertions, 3 deletions
diff --git a/src/apt.cpp b/src/apt.cpp
index f81fbbe..99b753f 100644
--- a/src/apt.cpp
+++ b/src/apt.cpp
@@ -222,7 +222,7 @@ TQString AptProtocol::make_html_form() const
AptProtocol::AptProtocol( const TQCString &pool_socket, const TQCString &app_socket )
: SlaveBase( "tdeio_apt", pool_socket, app_socket ),
- m_adept_batch(0), m_parser(0)
+ m_adept_batch(0), m_parser()
{
TDEStandardDirs* dirs = TDEGlobal::dirs();
@@ -257,7 +257,7 @@ TQString AptProtocol::header_background() const { return m_header_background; }
void AptProtocol::token_dispatch(const TQString& name, const TQString& val)
{
- if (m_parser.get())
+ if (m_parser)
(*m_parser)(this, name, val);
}
diff --git a/src/apt.h b/src/apt.h
index 879582c..a066415 100644
--- a/src/apt.h
+++ b/src/apt.h
@@ -85,7 +85,7 @@ private slots:
void token_dispatch(const TQString& tag, const TQString& value);
private:
- std::auto_ptr<Parsers::Parser> m_parser;
+ std::unique_ptr<Parsers::Parser> m_parser;
/** apt-cache search
* Performs apt-cache search, with the query encoded in url.query()