[libcalamaresui] Paste TCP port is quint16

- no sense in feeding in an int (and getting a compiler warning
   for narrowing) into something that by spec is a 16-bit value.
This commit is contained in:
Adriaan de Groot 2019-08-09 16:41:59 +02:00
parent 41173360a7
commit 91d327b224
2 changed files with 4 additions and 2 deletions

View File

@ -29,7 +29,7 @@ namespace CalamaresUtils
{ {
QString QString
sendLogToPastebin( QObject* parent, const QString& ficheHost, int fichePort ) sendLogToPastebin( QObject* parent, const QString& ficheHost, quint16 fichePort )
{ {
QString pasteUrlFmt = parent->tr( "Install log posted to:\n%1" ); QString pasteUrlFmt = parent->tr( "Install log posted to:\n%1" );
QFile pasteSourceFile( Logger::logFile() ); QFile pasteSourceFile( Logger::logFile() );

View File

@ -19,6 +19,8 @@
#ifndef UTILS_PASTE_H #ifndef UTILS_PASTE_H
#define UTILS_PASTE_H #define UTILS_PASTE_H
#include <qglobal.h> // for quint16
class QObject; class QObject;
class QString; class QString;
@ -29,7 +31,7 @@ namespace CalamaresUtils
* *
* Returns the (string) URL that the pastebin gives us. * Returns the (string) URL that the pastebin gives us.
*/ */
QString sendLogToPastebin( QObject* parent, const QString& ficheHost, int fichePort ); QString sendLogToPastebin( QObject* parent, const QString& ficheHost, quint16 fichePort );
} // namespace CalamaresUtils } // namespace CalamaresUtils