diff options
author | Rafael Roquetto <rafael.roquetto.qnx@kdab.com> | 2012-10-13 16:12:28 -0300 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2012-10-13 23:24:01 +0200 |
commit | 7edaf253d5e5baa0368e08d2cec82ad9fb507f21 (patch) | |
tree | 91e288a2fb44c4b2630afeb168b0b205a6cbf297 /src/plugins/platforms/qnx/qqnxinputcontext_imf.cpp | |
parent | 386eb2a5c0ebbdf101a3c2e3d094402223669d6a (diff) |
QNX: code cleanup, use '0' instead of 'NULL'
Qt coding style uses always 0. NULL is wrong.
Change-Id: I163677b512214f853677d21d75f13142fe2ca88d
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
Diffstat (limited to 'src/plugins/platforms/qnx/qqnxinputcontext_imf.cpp')
-rw-r--r-- | src/plugins/platforms/qnx/qqnxinputcontext_imf.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/plugins/platforms/qnx/qqnxinputcontext_imf.cpp b/src/plugins/platforms/qnx/qqnxinputcontext_imf.cpp index 72a967d5e5..30ca8a5c48 100644 --- a/src/plugins/platforms/qnx/qqnxinputcontext_imf.cpp +++ b/src/plugins/platforms/qnx/qqnxinputcontext_imf.cpp @@ -571,7 +571,7 @@ spannable_string_t *toSpannableString(const QString &text) spannable_string_t *pString = reinterpret_cast<spannable_string_t *>(malloc(sizeof(spannable_string_t))); pString->str = (wchar_t *)malloc(sizeof(wchar_t) * text.length() + 1); pString->length = text.length(); - pString->spans = NULL; + pString->spans = 0; pString->spans_count = 0; const QChar *pData = text.constData(); @@ -601,7 +601,7 @@ static bool s_imfInitFailed = false; static bool imfAvailable() { - static bool s_imfDisabled = getenv("DISABLE_IMF") != NULL; + static bool s_imfDisabled = getenv("DISABLE_IMF") != 0; static bool s_imfReady = false; if ( s_imfInitFailed || s_imfDisabled) { @@ -611,7 +611,7 @@ static bool imfAvailable() return true; } - if ( p_imf_client_init == NULL ) { + if ( p_imf_client_init == 0 ) { void *handle = dlopen("libinput_client.so.1", 0); if ( handle ) { p_imf_client_init = (int32_t (*)()) dlsym(handle, "imf_client_init"); @@ -632,8 +632,8 @@ static bool imfAvailable() s_imfReady = true; } else { - p_ictrl_open_session = NULL; - p_ictrl_dispatch_event = NULL; + p_ictrl_open_session = 0; + p_ictrl_dispatch_event = 0; s_imfDisabled = true; qCritical() << Q_FUNC_INFO << "libinput_client.so.1 did not contain the correct symbols, library mismatch? IMF services are disabled."; return false; |