dovecot-2.2-pigeonhole: lib-sieve: util: Fixed source code inden...

pigeonhole at rename-it.nl pigeonhole at rename-it.nl
Fri Jan 8 16:26:16 UTC 2016


details:   http://hg.rename-it.nl/dovecot-2.2-pigeonhole/rev/59a9b4f2d056
changeset: 2204:59a9b4f2d056
user:      Stephan Bosch <stephan at rename-it.nl>
date:      Thu Jan 07 22:09:50 2016 +0100
description:
lib-sieve: util: Fixed source code indentation in realpath.c.

diffstat:

 src/lib-sieve/util/realpath.c |  20 ++++++++++----------
 1 files changed, 10 insertions(+), 10 deletions(-)

diffs (68 lines):

diff -r 00608fdd9826 -r 59a9b4f2d056 src/lib-sieve/util/realpath.c
--- a/src/lib-sieve/util/realpath.c	Mon Jan 04 01:19:02 2016 +0100
+++ b/src/lib-sieve/util/realpath.c	Thu Jan 07 22:09:50 2016 +0100
@@ -67,7 +67,7 @@
 
 		/* find end of path segment */
 		for (segend = p; *segend != '\0' && *segend != '/'; segend++);
-	
+
 		if (segend == p)
 			break; /* '\0' */
 		seglen = segend - p;
@@ -87,11 +87,11 @@
 
 			/* allocate space if necessary */
 			if ((npath_pos + seglen + 1) >= (npath + asize)) {
-			  ptrdiff_t npath_offset = npath_pos - npath;
+				ptrdiff_t npath_offset = npath_pos - npath;
 				asize = nearest_power(npath_offset + seglen + 2);
 				npath = t_buffer_reget(npath, asize);
-		    npath_pos = npath + npath_offset;
-		  }
+				npath_pos = npath + npath_offset;
+			}
 
 			/* copy segment to normalized path */
 			(void)memmove(npath_pos, p, seglen);
@@ -102,7 +102,7 @@
 			/* stat path up to here (segend points to tail) */
 			*npath_pos = '\0';
 			if (lstat(npath, &st) < 0)
-			  return -1;
+				return -1;
 
 			if (S_ISLNK (st.st_mode)) {
 				/* symlink */
@@ -112,7 +112,7 @@
 				ssize_t ret;
 
 				/* limit link dereferences */
-			  if (++link_count > REALPATH_MAX_SYMLINKS) {
+				if (++link_count > REALPATH_MAX_SYMLINKS) {
 					errno = ELOOP;
 					return -1;
 				}
@@ -129,7 +129,7 @@
 					asize = nearest_power((npath_offset + espace + lsize) + 1);
 					lsize = asize - (npath_offset + espace);
 					npath = t_buffer_reget(npath, asize);
-				  npath_pos = npath + npath_offset;
+					npath_pos = npath + npath_offset;
 				}
 
 				if (ltlen > 0) {
@@ -146,10 +146,10 @@
 						return -1;
 					if ((size_t)ret < lsize)
 						break;
-				
+
 					/* sum of new symlink content length and path tail length may not
-						 exeed maximum */
-				  if ((size_t)(ret + tlen) >= REALPATH_MAX_PATH) {
+					   exeed maximum */
+					if ((size_t)(ret + tlen) >= REALPATH_MAX_PATH) {
 						errno = ENAMETOOLONG;
 						return -1;
 					}


More information about the dovecot-cvs mailing list