]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
style: fix coding style issues
authorChristian Goeschel Ndjomouo <cgoesc2@wgu.edu>
Thu, 1 Jan 2026 04:10:57 +0000 (23:10 -0500)
committerChristian Goeschel Ndjomouo <cgoesc2@wgu.edu>
Thu, 1 Jan 2026 04:10:57 +0000 (23:10 -0500)
Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
17 files changed:
disk-utils/fdisk-list.c
lib/mangle.c
lib/pty-session.c
libmount/src/context.c
libmount/src/context_umount.c
libmount/src/fs.c
libmount/src/hook_loopdev.c
libmount/src/hook_mount.c
libmount/src/tab_listmount.c
libmount/src/utils.c
libsmartcols/src/column.c
libsmartcols/src/filter-param.c
libsmartcols/src/filter.c
login-utils/lslogins.c
misc-utils/lsblk-properties.c
term-utils/script.c
term-utils/scriptlive.c

index 04ee2b431f23eeb210aa07e5354e3e53e92b700b..948797f2bfa12d43da1c04f103b7b1fa80a02f61 100644 (file)
@@ -327,7 +327,7 @@ int list_freespace_get_table(struct fdisk_context *cxt,
                }
 
                if (fdisk_partition_has_size(pa)) {
-                       uintmax_t sz = fdisk_partition_get_size(pa);;
+                       uintmax_t sz = fdisk_partition_get_size(pa);
 
                        sumsize += sz;
 
index 4c505bce700172616ae4002f7fe5e4477cc8bf8e..e5b47aae1ac0532c67d0b25d1b7681b391ae9d72 100644 (file)
@@ -106,7 +106,7 @@ size_t unescape_to_buffer(const char *s, const char *wanted, char *buf, size_t l
                        s += 2;
                        sz += 2;
                } else {
-                       *buf++ = *s++;;
+                       *buf++ = *s++;
                        sz++;
                }
        }
index e9db4988bbaff6823987a8fb76b1b2d71e60d5db..94633774f2ab454efbf9e9427115cc67c9737b8f 100644 (file)
@@ -644,7 +644,7 @@ int ul_pty_proxy_master(struct ul_pty *pty)
 
                /* note, callback usually updates @next_callback_time */
                if (timerisset(&pty->next_callback_time)) {
-                       struct timeval now = { 0 };;
+                       struct timeval now = { 0 };
 
                        DBG(IO, ul_debugobj(pty, " callback requested"));
                        gettime_monotonic(&now);
index 6dfc5913dfd509656e2235a49d7c8ef4b260f754..3f1119000a555988382c34397e57ebc4e06e9e91 100644 (file)
@@ -2846,7 +2846,7 @@ int mnt_context_read_mesgs(struct libmnt_context *cxt, int fd)
                        continue;
 
                mnt_context_append_mesg(cxt, (char *) buf);
-               count++;;
+               count++;
        }
 
        errno = errsv;
index 854b704b05a714363e947ecf2062dc8163ec0671..7a452ea0a3fc4a54df9af438d44c380cef02952f 100644 (file)
@@ -459,7 +459,7 @@ static int is_fuse_usermount(struct libmnt_context *cxt, int *errsv)
        struct libmnt_optlist *ol;
        struct libmnt_opt *opt;
        const char *type = mnt_fs_get_fstype(cxt->fs);
-       const char *val = NULL;;
+       const char *val = NULL;
        uid_t uid, entry_uid;
 
        *errsv = 0;
index 6147d1f534c65da69e450e1595409d109278f1f6..e6a0fa1e2859022ec179fe9da1cdf4b56a07b060 100644 (file)
@@ -627,7 +627,7 @@ const char *mnt_fs_get_target(struct libmnt_fs *fs)
 #ifdef HAVE_STATMOUNT_API
        mnt_fs_try_statmount(fs, target, STATMOUNT_MNT_POINT);
 #endif
-       return fs->target;;
+       return fs->target;
 }
 
 /**
index 0bb97e59b4e1618774106c1d9a954b8f6bf7d18d..a7cb13a08b23357cf047594a3b686406aca7e61e 100644 (file)
@@ -458,7 +458,7 @@ static int is_loopdev_required(struct libmnt_context *cxt, struct libmnt_optlist
 
                rc = mnt_context_guess_srcpath_fstype(cxt, &autotype);
                if (rc) {
-                       free(autotype);;
+                       free(autotype);
                        DBG(CXT, ul_debugobj(cxt, "failed to guess regfile FS type [rc=%d]", rc));
                        return 0;
                }
index 77cf51ad3dbe41657ff6e3e5b54530839c99e40b..374078c97f8a74b19069539d3220f555686fe5a1 100644 (file)
@@ -233,7 +233,7 @@ static int create_superblock(struct libmnt_context *cxt,
        hookset_set_syscall_status(cxt, "fsconfig", rc == 0);
 
        DBG(HOOK, ul_debugobj(hs, " create done [rc=%d]", rc));
-       return rc != 0 && errno ? -errno : rc;;
+       return rc != 0 && errno ? -errno : rc;
 }
 
 static int open_fs_configuration_context(struct libmnt_context *cxt,
index e4a1c2a529ec86f23e7d91c6dc3504ba621f9659..b3aa40aca5eb0943243e3d6ba4bfecf9c8422733 100644 (file)
@@ -126,7 +126,7 @@ static int table_init_listmount(struct libmnt_table *tb, size_t stepsiz)
 
                        free(tb->lsmnt);
                }
-               tb->lsmnt = ls;;
+               tb->lsmnt = ls;
        }
 
        DBG(TAB, ul_debugobj(tb, "listmount: init [step=%zu]", ls->stepsiz));
index 49166f96fd7c1343ac7552c32dd0b0196301d947..863879718dfd031b8e673975f9bb25f2978ddb2e 100644 (file)
@@ -745,7 +745,7 @@ int mnt_get_uid(const char *username, uid_t *uid)
                        "cannot convert '%s' username to UID", username));
                if (errno == 0)
                        errno = EINVAL;
-               rc = -errno;;
+               rc = -errno;
        }
 
        free(buf);
@@ -774,7 +774,7 @@ int mnt_get_gid(const char *groupname, gid_t *gid)
                        "cannot convert '%s' groupname to GID", groupname));
                if (errno == 0)
                        errno = EINVAL;
-               rc = -errno;;
+               rc = -errno;
        }
 
        free(buf);
index a3a9d9fed327196f582ebc1aabb0d7aa259c5180..a36e54690e00966dcfab3011c4ee7a2c5162f49d 100644 (file)
@@ -1141,7 +1141,7 @@ int scols_column_greatest_wrap(
                        char **data)
 {
        size_t maxsz = 0;
-       char *res = NULL;;
+       char *res = NULL;
 
        if (!scols_column_is_customwrap(cl))
                return scols_column_next_wrap(cl, ce, data);
index c989aecfca635115a3eff3d0ce7b85907ea22e9b..b4700da1be10d16b443f77dced1ff1fbaaf1b590 100644 (file)
@@ -680,7 +680,7 @@ static int float_cast(int type, struct filter_param *n)
                n->val.num = fnum;
                break;
        case SCOLS_DATA_FLOAT:
-               break;;
+               break;
        case SCOLS_DATA_BOOLEAN:
                n->val.boolean = fnum > 0.0 ? true : false;
                break;
@@ -707,7 +707,7 @@ static int bool_cast(int type, struct filter_param *n)
                n->val.fnum = x ? 1.0 : 0.0;
                break;
        case SCOLS_DATA_BOOLEAN:
-               break;;
+               break;
        default:
                return -EINVAL;
        }
index d8068bb99dd809222904739a73e2eb445a028fc6..4923cd8025ed92ca67307af95916170bbe3fbf04 100644 (file)
@@ -486,7 +486,7 @@ unsigned long long scols_counter_get_result(struct libscols_counter *ct)
  */
 const char *scols_counter_get_name(struct libscols_counter *ct)
 {
-       return ct ? ct->name : NULL;;
+       return ct ? ct->name : NULL;
 }
 
 /**
index 96d0299c638a4d63b5e337b5f258b216bb555ab9..aedc8ccc34bb7c9bd824028218857a590c9ea599 100644 (file)
@@ -897,7 +897,7 @@ static struct lslogins_user *get_user_info(struct lslogins_control *ctl, const c
                        if (user_wtmp) {
                                mem2strcpy(user->last_tty, user_wtmp->ut_line,
                                                sizeof(user_wtmp->ut_line),
-                                               sizeof(user_wtmp->ut_line) + 1);;
+                                               sizeof(user_wtmp->ut_line) + 1);
                        }  else
                                get_lastlog(ctl, user->uid, user->login, user->last_tty, LASTLOG_LINE);
                        break;
@@ -908,7 +908,7 @@ static struct lslogins_user *get_user_info(struct lslogins_control *ctl, const c
                        if (user_wtmp) {
                                mem2strcpy(user->last_hostname, user_wtmp->ut_host,
                                                sizeof(user_wtmp->ut_host),
-                                               sizeof(user_wtmp->ut_host) + 1);;
+                                               sizeof(user_wtmp->ut_host) + 1);
                        }  else
                                get_lastlog(ctl, user->uid, user->login, user->last_hostname, LASTLOG_HOST);
                        break;
@@ -923,7 +923,7 @@ static struct lslogins_user *get_user_info(struct lslogins_control *ctl, const c
                                user->failed_tty = xmalloc(sizeof(user_btmp->ut_line) + 1);
                                mem2strcpy(user->failed_tty, user_btmp->ut_line,
                                                sizeof(user_btmp->ut_line),
-                                               sizeof(user_btmp->ut_line) + 1);;
+                                               sizeof(user_btmp->ut_line) + 1);
                        }
                        break;
                case COL_HUSH_STATUS:
index 1f80f3e18aee13934a55c0add4f774c5c5b81edd..0a5d86c72206e72d5a6f15cc71a22272c5432768 100644 (file)
@@ -300,7 +300,7 @@ static struct lsblk_devprop *get_properties_by_blkid(struct lsblk_device *dev)
        if (!dev->size)
                goto done;
        if (getuid() != 0)
-               goto done;;                             /* no permissions to read from the device */
+               goto done;                              /* no permissions to read from the device */
 
        DBG(DEV, ul_debugobj(dev, " properties by blkid"));
 
index 4e302347f22b0646f73b828f14b8aa1bafa431d0..6a57e534aaada17ee7f6d132a456bf8b97d1d609 100644 (file)
@@ -561,7 +561,7 @@ static ssize_t __attribute__ ((__format__ (__printf__, 3, 4)))
                rc = vsnprintf(msg, sizeof(msg), msgfmt, ap);
                va_end(ap);
                if (rc < 0)
-                       *msg = '\0';;
+                       *msg = '\0';
        }
 
        if (*msg)
@@ -599,7 +599,7 @@ static ssize_t log_info(struct script_control *ctl, const char *name, const char
                rc = vsnprintf(msg, sizeof(msg), msgfmt, ap);
                va_end(ap);
                if (rc < 0)
-                       *msg = '\0';;
+                       *msg = '\0';
        }
 
        if (*msg)
index 6ac685506f208c490630d89bae69754634e602f6..f36998a9945e95246dcc00116753b61b37e7c819 100644 (file)
@@ -144,7 +144,7 @@ static int mainloop_cb(void *data)
 
        /* emit previous waiting step */
        if (ss->step && !replay_step_is_empty(ss->step)) {
-               int fd = ul_pty_get_childfd(ss->pty);;
+               int fd = ul_pty_get_childfd(ss->pty);
 
                rc = replay_emit_step_data(ss->setup, ss->step, fd);
                fdatasync(fd);