mirror of
https://github.com/qbittorrent/qBittorrent
synced 2025-07-16 02:03:07 -07:00
Replace C-style casts with C++ ones
This commit is contained in:
parent
e3671050d1
commit
74cecb1b6c
20 changed files with 41 additions and 39 deletions
|
@ -224,7 +224,9 @@ bool FileSystemWatcher::isNetworkFileSystem(QString path)
|
|||
// XXX: should we make sure HAVE_STRUCT_FSSTAT_F_FSTYPENAME is defined?
|
||||
return ((strcmp(buf.f_fstypename, "nfs") == 0) || (strcmp(buf.f_fstypename, "cifs") == 0) || (strcmp(buf.f_fstypename, "smbfs") == 0));
|
||||
#else
|
||||
return ((buf.f_type == (long)CIFS_MAGIC_NUMBER) || (buf.f_type == (long)NFS_SUPER_MAGIC) || (buf.f_type == (long)SMB_SUPER_MAGIC));
|
||||
return ((buf.f_type == static_cast<long>(CIFS_MAGIC_NUMBER))
|
||||
|| (buf.f_type == static_cast<long>(NFS_SUPER_MAGIC))
|
||||
|| (buf.f_type == static_cast<long>(SMB_SUPER_MAGIC)));
|
||||
#endif
|
||||
}
|
||||
else {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue