diff options
author | Ray-V <[email protected]> | 2022-11-23 11:44:23 +0000 |
---|---|---|
committer | Ray-V <[email protected]> | 2022-11-24 12:14:05 +0000 |
commit | 76c89b83c57ca3adaf305a0405618ca5b58a38cd (patch) | |
tree | e317687df5827659809f861ccf7f130182dea6db /src | |
parent | 6bcea37ca23e5017679c653d5ac572b2c7fed204 (diff) | |
download | kile-76c89b83c57ca3adaf305a0405618ca5b58a38cd.tar.gz kile-76c89b83c57ca3adaf305a0405618ca5b58a38cd.zip |
Insert an explicit cast for -Wc++11-narrowing error
clang/i?86 build
Resolves issue #4
Signed-off-by: Ray-V <[email protected]>
Diffstat (limited to 'src')
-rw-r--r-- | src/kile/kilejscript.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/kile/kilejscript.cpp b/src/kile/kilejscript.cpp index 2f103a6..2e69338 100644 --- a/src/kile/kilejscript.cpp +++ b/src/kile/kilejscript.cpp @@ -67,8 +67,8 @@ void KJSCPUGuard::start(unsigned int ms, unsigned int i_ms) { oldAlarmHandler = signal(SIGVTALRM, alarmHandler); itimerval tv = { - { i_ms / 1000, (i_ms % 1000) * 1000 }, - { ms / 1000, (ms % 1000) * 1000 } + { static_cast<__time_t>( i_ms / 1000 ), static_cast<__suseconds_t>( (i_ms % 1000) * 1000 ) }, + { static_cast<__time_t>( ms / 1000 ), static_cast<__suseconds_t>( (ms % 1000) * 1000 ) } }; setitimer(ITIMER_VIRTUAL, &tv, &oldtv); } |