summaryrefslogtreecommitdiffstats
path: root/src/corelib/doc/snippets/code/src_corelib_io_qtextstream.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/corelib/doc/snippets/code/src_corelib_io_qtextstream.cpp')
-rw-r--r--src/corelib/doc/snippets/code/src_corelib_io_qtextstream.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/corelib/doc/snippets/code/src_corelib_io_qtextstream.cpp b/src/corelib/doc/snippets/code/src_corelib_io_qtextstream.cpp
index 5cfeeeac85..c76a0f1f3b 100644
--- a/src/corelib/doc/snippets/code/src_corelib_io_qtextstream.cpp
+++ b/src/corelib/doc/snippets/code/src_corelib_io_qtextstream.cpp
@@ -1,7 +1,7 @@
/****************************************************************************
**
-** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
-** Contact: http://www.qt-project.org/legal
+** Copyright (C) 2015 The Qt Company Ltd.
+** Contact: http://www.qt.io/licensing/
**
** This file is part of the documentation of the Qt Toolkit.
**
@@ -17,8 +17,8 @@
** notice, this list of conditions and the following disclaimer in
** the documentation and/or other materials provided with the
** distribution.
-** * Neither the name of Digia Plc and its Subsidiary(-ies) nor the names
-** of its contributors may be used to endorse or promote products derived
+** * Neither the name of The Qt Company Ltd nor the names of its
+** contributors may be used to endorse or promote products derived
** from this software without specific prior written permission.
**
**
@@ -51,9 +51,9 @@ if (data.open(QFile::WriteOnly | QFile::Truncate)) {
//! [1]
QTextStream stream(stdin);
QString line;
-do {
- line = stream.readLine();
-} while (!line.isNull());
+while (stream.readLine(&line)) {
+ ...
+}
//! [1]