]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
global: Fix whitespace -> tabs
authorFred Morcos <fred.morcos@open-xchange.com>
Mon, 2 Dec 2024 07:05:29 +0000 (08:05 +0100)
committerFred Morcos <fred.morcos@open-xchange.com>
Thu, 12 Dec 2024 11:14:09 +0000 (12:14 +0100)
src/lib-index/mail-index-transaction-update.c
src/lib-index/mail-index-util.c
src/lib-index/mail-index.c
src/lib-index/mail-index.h
src/lib/array.h
src/lib/buffer.c
src/lib/file-dotlock.c
src/lib/lib.h
src/lib/net.c

index 9535b0409c017e44d74108892cd69434f3203880..e0c5434597857a0cf4536ee28e84e8576c669d04 100644 (file)
@@ -157,7 +157,7 @@ void mail_index_update_day_headers(struct mail_index_transaction *t,
 void mail_index_append(struct mail_index_transaction *t, uint32_t uid,
                       uint32_t *seq_r)
 {
-        struct mail_index_record *rec;
+       struct mail_index_record *rec;
 
        i_assert(!t->no_appends);
 
@@ -1017,7 +1017,7 @@ void mail_index_update_ext(struct mail_index_transaction *t, uint32_t seq,
                           uint32_t ext_id, const void *data, void *old_data_r)
 {
        struct mail_index *index = t->view->index;
-        const struct mail_index_registered_ext *rext;
+       const struct mail_index_registered_ext *rext;
        const struct mail_transaction_ext_intro *intro;
        uint16_t record_size;
        ARRAY_TYPE(seq_array) *array;
index b61cf8d32fda8de9b8ada8e6a4bda631bcefb982..a865cea4c8fae4eac2045ec8c47cf756fd0d1be1 100644 (file)
@@ -139,7 +139,7 @@ bool mail_index_seq_array_add(ARRAY_TYPE(seq_array) *array, uint32_t seq,
                return TRUE;
        } else {
                /* insert */
-                p = array_insert_space(array, idx);
+               p = array_insert_space(array, idx);
                memcpy(p, &seq, sizeof(seq));
                memcpy(PTR_OFFSET(p, sizeof(seq)), record, record_size);
                return FALSE;
index e6be908bbfa664fba527fc87c4f4c271bfa647f3..f6b73f381fe3e7819a7d6465062444b4413473e7 100644 (file)
@@ -308,7 +308,7 @@ void mail_index_ext_register_resize_defaults(struct mail_index *index,
 bool mail_index_ext_lookup(struct mail_index *index, const char *name,
                           uint32_t *ext_id_r)
 {
-        const struct mail_index_registered_ext *extensions;
+       const struct mail_index_registered_ext *extensions;
        unsigned int i, count;
 
        extensions = array_get(&index->extensions, &count);
@@ -488,7 +488,7 @@ int mail_index_try_open_only(struct mail_index *index)
        i_assert(index->fd == -1);
        i_assert(!MAIL_INDEX_IS_IN_MEMORY(index));
 
-        /* Note that our caller must close index->fd by itself. */
+       /* Note that our caller must close index->fd by itself. */
        if (index->readonly)
                errno = EACCES;
        else {
@@ -518,7 +518,7 @@ mail_index_try_open(struct mail_index *index)
 {
        int ret;
 
-        i_assert(index->fd == -1);
+       i_assert(index->fd == -1);
 
        if (MAIL_INDEX_IS_IN_MEMORY(index))
                return 0;
@@ -538,7 +538,7 @@ mail_index_try_open(struct mail_index *index)
 int mail_index_create_tmp_file(struct mail_index *index,
                               const char *path_prefix, const char **path_r)
 {
-        mode_t old_mask;
+       mode_t old_mask;
        const char *path;
        int fd;
 
index f296c293d00fa93f74df2c76ceed69fa6434f90c..e3f6baf0d3d7d0db542cdb1c37746bd76448ab5c 100644 (file)
@@ -187,7 +187,7 @@ struct mail_keywords {
        unsigned int count;
        int refcount;
 
-        /* variable sized list of keyword indexes */
+       /* variable sized list of keyword indexes */
        unsigned int idx[FLEXIBLE_ARRAY_MEMBER];
 };
 
index 6558c1cc29e859aac4d5dfc0669e8730abb28a22..4de3513ee56527875e97a5db80548cfdc58ea75f 100644 (file)
        struct foo *foo = array_idx(foos, 0);
    }
    struct foo_manager {
-        ARRAY_TYPE(foo) foos; // pedantically, ARRAY(struct foo) is a different type
+       ARRAY_TYPE(foo) foos; // pedantically, ARRAY(struct foo) is a different type
    };
    // ...
-        do_foo(&my_foo_manager->foos); // No compiler warning about mismatched types
+       do_foo(&my_foo_manager->foos); // No compiler warning about mismatched types
 
 */
 #include "array-decl.h"
index a3ba1d66c4d060e6cab782ab277a126e44ac39a5..c85f1e61db613d4845075dd48ac819e64ecf7d09 100644 (file)
@@ -507,4 +507,3 @@ buffer_truncate_rshift_bits(buffer_t *buf, size_t bits)
                buffer_set_used_size(buf, 0);
        }
 }
-
index ad14ef0ff01ba9e6886602cf68ec7a591cc8984c..29901bf315627db89b1a9430b73b15ea9a717139 100644 (file)
@@ -366,7 +366,7 @@ static int try_create_lock_hardlink(struct lock_info *lock_info, bool write_pid,
                        }
                }
 
-                lock_info->temp_path = str_c(tmp_path);
+               lock_info->temp_path = str_c(tmp_path);
        } else if (fstat(lock_info->fd, &st) < 0) {
                i_error("fstat(%s) failed: %m", lock_info->temp_path);
                return -1;
@@ -577,7 +577,7 @@ dotlock_create(struct dotlock *dotlock, enum dotlock_create_flags flags,
                        dotlock->ino = st.st_ino;
 
                        dotlock->fd = lock_info.fd;
-                        dotlock->lock_time = now;
+                       dotlock->lock_time = now;
                        lock_info.fd = -1;
 
                        if (st.st_ctime + MAX_TIME_DIFF < now ||
@@ -722,7 +722,7 @@ int file_dotlock_delete(struct dotlock **dotlock_p)
 {
        struct dotlock *dotlock;
        const char *lock_path;
-        struct stat st;
+       struct stat st;
        int ret;
 
        dotlock = *dotlock_p;
index 474fbf190b8cbd08e62808807221fd1053c728eb..5d6e35038d2ed64cf89694086c610db05d352278 100644 (file)
@@ -128,12 +128,12 @@ uint32_t i_rand_limit(uint32_t upper_bound);
 
 static inline unsigned short i_rand_ushort(void)
 {
-        return i_rand_limit(USHRT_MAX + 1);
+       return i_rand_limit(USHRT_MAX + 1);
 }
 
 static inline unsigned char i_rand_uchar(void)
 {
-        return i_rand_limit(UCHAR_MAX + 1);
+       return i_rand_limit(UCHAR_MAX + 1);
 }
 
 /* Returns a random integer >= min_val, and <= max_val. */
@@ -177,7 +177,7 @@ static inline int i_faccessat2(int fd, const char *file, int type, int flag)
                        return ret;
        }
 #endif
-        return faccessat(fd, file, type, flag);
+       return faccessat(fd, file, type, flag);
 }
 
 #endif
index 5ef450af0716ba77cf1076aefd7ed58c7c2ed037..d657882d393adf5af43f15c50ecfd41ac06a4ebd 100644 (file)
@@ -104,7 +104,7 @@ int net_ip_cmp(const struct ip_addr *ip1, const struct ip_addr *ip2)
 
 unsigned int net_ip_hash(const struct ip_addr *ip)
 {
-        const unsigned char *p;
+       const unsigned char *p;
        unsigned int len, g, h = 0;
 
        if (ip->family == AF_INET6) {
@@ -165,7 +165,7 @@ sin_get_ip(const union sockaddr_union *so, struct ip_addr *ip)
 static inline void sin_set_port(union sockaddr_union *so, in_port_t port)
 {
        if (so->sin.sin_family == AF_INET6)
-                so->sin6.sin6_port = htons(port);
+               so->sin6.sin6_port = htons(port);
        else if (so->sin.sin_family == AF_INET)
                so->sin.sin_port = htons(port);
        else
@@ -190,12 +190,12 @@ static int net_connect_ip_once(const struct ip_addr *ip, in_port_t port,
 
        if (my_ip != NULL && ip->family != my_ip->family) {
                i_warning("net_connect_ip(): ip->family != my_ip->family");
-                my_ip = NULL;
+               my_ip = NULL;
        }
 
        /* create the socket */
        i_zero(&so);
-        so.sin.sin_family = ip->family;
+       so.sin.sin_family = ip->family;
        fd = socket(ip->family, sock_type, 0);
 
        if (fd == -1) {
@@ -231,7 +231,7 @@ static int net_connect_ip_once(const struct ip_addr *ip, in_port_t port,
        if (ret < 0 && WSAGetLastError() != WSAEWOULDBLOCK)
 #endif
        {
-                i_close_fd(&fd);
+               i_close_fd(&fd);
                return -1;
        }
 
@@ -286,7 +286,7 @@ int net_try_bind(const struct ip_addr *ip)
 
        /* create the socket */
        i_zero(&so);
-        so.sin.sin_family = ip->family;
+       so.sin.sin_family = ip->family;
        fd = socket(ip->family, SOCK_STREAM, 0);
        if (fd == -1) {
                i_error("socket() failed: %m");
@@ -331,7 +331,7 @@ int net_connect_unix(const char *path)
        /* connect */
        ret = connect(fd, &sa.sa, sizeof(sa));
        if (ret < 0 && errno != EINPROGRESS) {
-                i_close_fd(&fd);
+               i_close_fd(&fd);
                return -1;
        }
 
@@ -531,7 +531,7 @@ int net_listen_full(const struct ip_addr *my_ip, in_port_t *port,
                }
        }
 
-        /* error */
+       /* error */
        i_close_fd(&fd);
        return -1;
 }
@@ -664,7 +664,7 @@ ssize_t net_receive(int fd, void *buf, size_t len)
                        return 0;
 
                if (errno == ECONNRESET || errno == ETIMEDOUT) {
-                        /* treat as disconnection */
+                       /* treat as disconnection */
                        return -2;
                }
        }
@@ -680,10 +680,10 @@ int net_gethostbyname(const char *addr, struct ip_addr **ips,
        struct addrinfo hints, *ai, *origai;
        struct ip_addr ip;
        int host_error;
-        int count;
+       int count;
 
        *ips = NULL;
-        *ips_count = 0;
+       *ips_count = 0;
 
        /* support [ipv6] style addresses here so they work globally */
        if (addr[0] == '[' && net_addr2ip(addr, &ip) == 0) {
@@ -704,16 +704,16 @@ int net_gethostbyname(const char *addr, struct ip_addr **ips,
                return host_error;
        }
 
-        /* get number of IPs */
-        origai = ai;
+       /* get number of IPs */
+       origai = ai;
        for (count = 0; ai != NULL; ai = ai->ai_next)
                count++;
        i_assert(count > 0);
 
-        *ips_count = count;
-        *ips = t_new(struct ip_addr, count);
+       *ips_count = count;
+       *ips = t_new(struct ip_addr, count);
 
-        count = 0;
+       count = 0;
        for (ai = origai; ai != NULL; ai = ai->ai_next, count++) {
                so = (union sockaddr_union *) ai->ai_addr;