diff --git a/kdecore/kcrash.cpp b/kdecore/kcrash.cpp index dd758f034..961dc2447 100644 --- a/kdecore/kcrash.cpp +++ b/kdecore/kcrash.cpp @@ -301,7 +301,10 @@ void KCrash::startDrKonqi( const char* argv[], int argc ) } long pid; read_socket(socket, buffer, header.arg_length); - pid = *((long *) buffer); + pid = 0; + for (int k=0;k(bits[0]); bit_array[0] = uchar(b & 0x07); b >>= 3; bit_array[1] = uchar(b & 0x07); b >>= 3; bit_array[2] = uchar(b & 0x07); b >>= 3; @@ -500,7 +500,7 @@ namespace { // Private. bit_array[6] = uchar(b & 0x07); b >>= 3; bit_array[7] = uchar(b & 0x07); b >>= 3; - b = (uint &) bits[3]; + b = static_cast(bits[3]); bit_array[8] = uchar(b & 0x07); b >>= 3; bit_array[9] = uchar(b & 0x07); b >>= 3; bit_array[10] = uchar(b & 0x07); b >>= 3; diff --git a/kioslave/iso/kiso.cpp b/kioslave/iso/kiso.cpp index f487ad2f5..1b052f6ab 100644 --- a/kioslave/iso/kiso.cpp +++ b/kioslave/iso/kiso.cpp @@ -249,7 +249,7 @@ static int mycallb(struct iso_directory_record *idr,void *udata) { if (!special) { if (iso->joliet) { for (i=0;i<(isonum_711(idr->name_len)-1);i+=2) { - TQChar ch( be2me_16(*((ushort*)&(idr->name[i]))) ); + TQChar ch( be2me_16( idr->name[i] ) ); if (ch==';') break; path+=ch; } @@ -304,14 +304,14 @@ void KIso::addBoot(struct el_torito_boot_descriptor* bootdesc) { i=1; be=boot.defentry; while (be) { - size=BootImageSize( isonum_711(((struct default_entry*) be->data)->media), - isonum_721(((struct default_entry*) be->data)->seccount)); + size=BootImageSize( isonum_711((reinterpret_cast(be->data))->media), + isonum_721((reinterpret_cast(be->data))->seccount)); path="Default Image"; if (i>1) path += " (" + TQString::number(i) + ")"; entry=new KIsoFile( this, path, dirent->permissions() & ~S_IFDIR, dirent->date(), dirent->adate(), dirent->cdate(), dirent->user(), dirent->group(), TQString::null, - isonum_731(((struct default_entry*) be->data)->start)<<11, size<<9 ); + isonum_731((reinterpret_cast(be->data))->start)<<11, size<<9 ); dirent->addEntry(entry); be=be->next; i++; diff --git a/krsync/rsyncconfigdialog.cpp b/krsync/rsyncconfigdialog.cpp index 2dcb1f128..56ac6c14e 100644 --- a/krsync/rsyncconfigdialog.cpp +++ b/krsync/rsyncconfigdialog.cpp @@ -177,6 +177,8 @@ int RsyncConfigDialog::getSyncMode() return 2; else if (rsync_rb3->isChecked() == true) return 3; + else + return 0; } int RsyncConfigDialog::getAutoSyncFlags() diff --git a/libkmid/alsaout.cc b/libkmid/alsaout.cc index 73effc2e3..4c7f48f4e 100644 --- a/libkmid/alsaout.cc +++ b/libkmid/alsaout.cc @@ -469,7 +469,7 @@ void AlsaOut::seqbuf_clean(void) void AlsaOut::wait(double ticks) { // SEQ_WAIT_TIME(((int)(ticks/convertrate))); - time=(long int)ticks; + time=static_cast(ticks); #ifdef MIDIOUTDEBUG printfdebug("Wait >\t ticks: %g\n",ticks); diff --git a/libkmid/track.cc b/libkmid/track.cc index f936906e7..ccaaf69d2 100644 --- a/libkmid/track.cc +++ b/libkmid/track.cc @@ -334,7 +334,7 @@ void MidiTrack::readEvent(MidiEvent *ev) case (ME_END_OF_TRACK) : i=0; j=0; - while ((note[i][j]==FALSE)&&(i<16)) + while ((i<16)&&(note[i][j]==FALSE)) { j++; if (j==128) { j=0; i++; };