diff options
Diffstat (limited to 'core')
-rw-r--r-- | core/btdiscovery.cpp | 4 | ||||
-rw-r--r-- | core/dive.c | 2 | ||||
-rw-r--r-- | core/exif.cpp | 2 | ||||
-rw-r--r-- | core/git-access.c | 2 | ||||
-rw-r--r-- | core/libdivecomputer.c | 2 | ||||
-rw-r--r-- | core/linux.c | 2 | ||||
-rw-r--r-- | core/macos.c | 2 | ||||
-rw-r--r-- | core/parse.c | 4 | ||||
-rw-r--r-- | core/profile.c | 2 | ||||
-rw-r--r-- | core/qthelper.cpp | 10 | ||||
-rw-r--r-- | core/subsurface-qt/DiveObjectHelper.cpp | 2 | ||||
-rw-r--r-- | core/subsurface-qt/SettingsObjectWrapper.cpp | 2 | ||||
-rw-r--r-- | core/windows.c | 2 |
13 files changed, 19 insertions, 19 deletions
diff --git a/core/btdiscovery.cpp b/core/btdiscovery.cpp index 394a90757..b3aab4fb4 100644 --- a/core/btdiscovery.cpp +++ b/core/btdiscovery.cpp @@ -47,9 +47,9 @@ static dc_descriptor_t *getDeviceType(QString btName) } if (!vendor.isEmpty() && !product.isEmpty()) - return(descriptorLookup.value(vendor + product)); + return descriptorLookup.value(vendor + product); - return(NULL); + return NULL; } BTDiscovery::BTDiscovery(QObject *parent) : m_btValid(false), diff --git a/core/dive.c b/core/dive.c index b405d7402..f3d5981c9 100644 --- a/core/dive.c +++ b/core/dive.c @@ -2720,7 +2720,7 @@ static int likely_same_dive(struct dive *a, struct dive *b) if (fuzz < 60) fuzz = 60; - return ((a->when <= b->when + fuzz) && (a->when >= b->when - fuzz)); + return (a->when <= b->when + fuzz) && (a->when >= b->when - fuzz); } /* diff --git a/core/exif.cpp b/core/exif.cpp index 8c47a514f..17983a0ff 100644 --- a/core/exif.cpp +++ b/core/exif.cpp @@ -897,6 +897,6 @@ time_t easyexif::EXIFInfo::epoch() tm.tm_hour = hour; tm.tm_min = min; tm.tm_sec = sec; - return (utc_mktime(&tm)); + return utc_mktime(&tm); } diff --git a/core/git-access.c b/core/git-access.c index 5619cf2a7..e9f17609b 100644 --- a/core/git-access.c +++ b/core/git-access.c @@ -728,7 +728,7 @@ static git_repository *create_and_push_remote(const char *localdir, const char * /* finally create an empty commit and push it to the remote */ if (do_git_save(repo, branch, remote, false, true)) return NULL; - return(repo); + return repo; } static git_repository *create_local_repo(const char *localdir, const char *remote, const char *branch, enum remote_transport rt) diff --git a/core/libdivecomputer.c b/core/libdivecomputer.c index c8afa47bf..be0bb01a5 100644 --- a/core/libdivecomputer.c +++ b/core/libdivecomputer.c @@ -1194,7 +1194,7 @@ dc_status_t libdc_buffer_parser(struct dive *dive, device_data_t *data, unsigned return rc; } dc_parser_destroy(parser); - return(DC_STATUS_SUCCESS); + return DC_STATUS_SUCCESS; } /* diff --git a/core/linux.c b/core/linux.c index de7991bc7..cbd71bcc8 100644 --- a/core/linux.c +++ b/core/linux.c @@ -228,5 +228,5 @@ void subsurface_console_exit(void) bool subsurface_user_is_root() { - return (geteuid() == 0); + return geteuid() == 0; } diff --git a/core/macos.c b/core/macos.c index 711b96a06..d2a760863 100644 --- a/core/macos.c +++ b/core/macos.c @@ -218,5 +218,5 @@ void subsurface_console_exit(void) bool subsurface_user_is_root() { - return (geteuid() == 0); + return geteuid() == 0; } diff --git a/core/parse.c b/core/parse.c index 69c064051..d83d8e331 100644 --- a/core/parse.c +++ b/core/parse.c @@ -187,8 +187,8 @@ void event_end(void) */ bool is_dive(void) { - return (cur_dive && - (cur_dive->dive_site_uuid || cur_dive->when || cur_dive->dc.samples)); + return cur_dive && + (cur_dive->dive_site_uuid || cur_dive->when || cur_dive->dc.samples); } void reset_dc_info(struct divecomputer *dc) diff --git a/core/profile.c b/core/profile.c index 78f3b2f57..373fb9640 100644 --- a/core/profile.c +++ b/core/profile.c @@ -1524,7 +1524,7 @@ struct plot_data *get_plot_details_new(struct plot_info *pi, int time, struct me } if (entry) plot_string(pi, entry, mb); - return (entry); + return entry; } /* Compare two plot_data entries and writes the results into a string */ diff --git a/core/qthelper.cpp b/core/qthelper.cpp index af0db074c..9bf52e29a 100644 --- a/core/qthelper.cpp +++ b/core/qthelper.cpp @@ -49,7 +49,7 @@ QString weight_string(int weight_in_grams) double lbs = grams_to_lbs(weight_in_grams); str = QString("%1").arg(lbs, 0, 'f', lbs >= 40.0 ? 0 : 1); } - return (str); + return str; } QString distance_string(int distanceInMeters) @@ -608,7 +608,7 @@ QString get_weight_string(weight_t weight, bool showunit) } else { str = QString("%1%2").arg(str).arg(showunit ? translate("gettextFromC", "lbs") : ""); } - return (str); + return str; } QString get_weight_unit() @@ -1017,7 +1017,7 @@ bool is_same_day(timestamp_t trip_when, timestamp_t dive_when) utc_mkdate(twhen, &tmt); } - return ((tmd.tm_mday == tmt.tm_mday) && (tmd.tm_mon == tmt.tm_mon) && (tmd.tm_year == tmt.tm_year)); + return (tmd.tm_mday == tmt.tm_mday) && (tmd.tm_mon == tmt.tm_mon) && (tmd.tm_year == tmt.tm_year); } QString get_trip_date_string(timestamp_t when, int nr, bool getday) @@ -1195,7 +1195,7 @@ void hashPicture(struct picture *picture) char *oldHash = copy_string(picture->hash); learnHash(picture, hashFile(localFilePath(picture->filename))); if (!empty_string(picture->hash) && !same_string(picture->hash, oldHash)) - mark_divelist_changed((true)); + mark_divelist_changed(true); free(oldHash); picture_free(picture); } @@ -1499,7 +1499,7 @@ void setCurrentAppState(QByteArray state) extern "C" bool in_planner() { - return (currentApplicationState == "PlanDive" || currentApplicationState == "EditPlannedDive"); + return currentApplicationState == "PlanDive" || currentApplicationState == "EditPlannedDive"; } extern "C" enum deco_mode decoMode() diff --git a/core/subsurface-qt/DiveObjectHelper.cpp b/core/subsurface-qt/DiveObjectHelper.cpp index 1d1bb2f00..03735bd85 100644 --- a/core/subsurface-qt/DiveObjectHelper.cpp +++ b/core/subsurface-qt/DiveObjectHelper.cpp @@ -119,7 +119,7 @@ QString DiveObjectHelper::gps_decimal() const prefs.coordinates_traditional = false; val = gps(); prefs.coordinates_traditional = savep; - return(val); + return val; } QString DiveObjectHelper::duration() const diff --git a/core/subsurface-qt/SettingsObjectWrapper.cpp b/core/subsurface-qt/SettingsObjectWrapper.cpp index 54b03aaf9..f508e993e 100644 --- a/core/subsurface-qt/SettingsObjectWrapper.cpp +++ b/core/subsurface-qt/SettingsObjectWrapper.cpp @@ -355,7 +355,7 @@ bool TechnicalDetailsSettings::calcndltts() const bool TechnicalDetailsSettings::buehlmann() const { - return (prefs.planner_deco_mode == BUEHLMANN); + return prefs.planner_deco_mode == BUEHLMANN; } int TechnicalDetailsSettings::gflow() const diff --git a/core/windows.c b/core/windows.c index f0b9eb22c..393286a06 100644 --- a/core/windows.c +++ b/core/windows.c @@ -437,5 +437,5 @@ void subsurface_console_exit(void) bool subsurface_user_is_root() { /* FIXME: Detect admin rights */ - return (false); + return false; } |