Fix some warnings

This commit is contained in:
Florian Märkl 2018-06-26 18:17:03 +02:00
parent bfa495321a
commit dd7a5f4eb6
5 changed files with 8 additions and 5 deletions

View File

@ -524,7 +524,7 @@ void CutterCore::setConfig(const QString &k, const QString &v)
void CutterCore::setConfig(const QString &k, int v) void CutterCore::setConfig(const QString &k, int v)
{ {
CORE_LOCK(); CORE_LOCK();
r_config_set_i(core_->config, k.toUtf8().constData(), static_cast<const unsigned long long int>(v)); r_config_set_i(core_->config, k.toUtf8().constData(), static_cast<ut64>(v));
} }
void CutterCore::setConfig(const QString &k, bool v) void CutterCore::setConfig(const QString &k, bool v)

View File

@ -7,8 +7,8 @@
AsyncTaskDialog::AsyncTaskDialog(AsyncTask::Ptr task, QWidget *parent) AsyncTaskDialog::AsyncTaskDialog(AsyncTask::Ptr task, QWidget *parent)
: QDialog(parent), : QDialog(parent),
task(task), ui(new Ui::AsyncTaskDialog),
ui(new Ui::AsyncTaskDialog) task(task)
{ {
ui->setupUi(this); ui->setupUi(this);

View File

@ -180,7 +180,7 @@ PyObject *api_internal_thread_set_async_exc(PyObject *, PyObject *args)
PyMethodDef CutterInternalMethods[] = { PyMethodDef CutterInternalMethods[] = {
{ {
"launch_ipykernel", (PyCFunction)api_internal_launch_ipykernel, METH_VARARGS | METH_KEYWORDS, "launch_ipykernel", reinterpret_cast<PyCFunction>((void *)api_internal_launch_ipykernel), METH_VARARGS | METH_KEYWORDS,
"Launch an IPython Kernel in a subinterpreter" "Launch an IPython Kernel in a subinterpreter"
}, },
{"kernel_interface_send_signal", (PyCFunction)api_internal_kernel_interface_send_signal, METH_VARARGS, ""}, {"kernel_interface_send_signal", (PyCFunction)api_internal_kernel_interface_send_signal, METH_VARARGS, ""},

View File

@ -59,7 +59,9 @@ int CommentsModel::rowCount(const QModelIndex &parent) const
int CommentsModel::columnCount(const QModelIndex&) const int CommentsModel::columnCount(const QModelIndex&) const
{ {
return (isNested() ? CommentsModel::NestedColumnCount : CommentsModel::ColumnCount); return (isNested()
? static_cast<int>(CommentsModel::NestedColumnCount)
: static_cast<int>(CommentsModel::ColumnCount));
} }
QVariant CommentsModel::data(const QModelIndex &index, int role) const QVariant CommentsModel::data(const QModelIndex &index, int role) const

View File

@ -36,6 +36,7 @@ QVariant RelocsModel::data(const QModelIndex &index, int role) const
default: default:
break; break;
} }
break;
case RelocsModel::RelocDescriptionRole: case RelocsModel::RelocDescriptionRole:
return QVariant::fromValue(reloc); return QVariant::fromValue(reloc);
case RelocsModel::AddressRole: case RelocsModel::AddressRole: