]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
Whitespace fixes
authorNick Mathewson <nickm@torproject.org>
Sun, 24 Aug 2014 17:32:39 +0000 (13:32 -0400)
committerNick Mathewson <nickm@torproject.org>
Sun, 24 Aug 2014 17:32:39 +0000 (13:32 -0400)
src/common/sandbox.c
src/common/torgzip.c
src/or/circuitlist.c

index e735feb0188ac848850e7a987bb601a57eb8bcd4..e215fe29267589c82164cc7272d85f7d9628c8a5 100644 (file)
@@ -99,7 +99,7 @@ static sandbox_cfg_t *filter_dynamic = NULL;
 #undef SCMP_CMP
 #define SCMP_CMP(a,b,c) ((struct scmp_arg_cmp){(a),(b),(c),0})
 #define SCMP_CMP_STR(a,b,c) \
-  ((struct scmp_arg_cmp){(a),(b),(intptr_t)(void*)(c),0})
+  ((struct scmp_arg_cmp) {(a),(b),(intptr_t)(void*)(c),0})
 #define SCMP_CMP4(a,b,c,d) ((struct scmp_arg_cmp){(a),(b),(c),(d)})
 /* We use a wrapper here because these masked comparisons seem to be pretty
  * verbose. Also, it's important to cast to scmp_datum_t before negating the
@@ -1172,28 +1172,6 @@ sandbox_cfg_allow_stat_filename(sandbox_cfg_t **cfg, char *file)
   return 0;
 }
 
-int
-sandbox_cfg_allow_stat_filename_array(sandbox_cfg_t **cfg, ...)
-{
-  int rc = 0;
-  char *fn = NULL;
-
-  va_list ap;
-  va_start(ap, cfg);
-
-  while ((fn = va_arg(ap, char*)) != NULL) {
-    rc = sandbox_cfg_allow_stat_filename(cfg, fn);
-    if (rc) {
-      log_err(LD_BUG,"(Sandbox) sandbox_cfg_allow_stat_filename_array fail");
-      goto end;
-    }
-  }
-
- end:
-  va_end(ap);
-  return 0;
-}
-
 int
 sandbox_cfg_allow_open_filename(sandbox_cfg_t **cfg, char *file)
 {
@@ -1229,28 +1207,6 @@ sandbox_cfg_allow_rename(sandbox_cfg_t **cfg, char *file1, char *file2)
   return 0;
 }
 
-int
-sandbox_cfg_allow_open_filename_array(sandbox_cfg_t **cfg, ...)
-{
-  int rc = 0;
-  char *fn = NULL;
-
-  va_list ap;
-  va_start(ap, cfg);
-
-  while ((fn = va_arg(ap, char*)) != NULL) {
-    rc = sandbox_cfg_allow_open_filename(cfg, fn);
-    if (rc) {
-      log_err(LD_BUG,"(Sandbox) sandbox_cfg_allow_open_filename_array fail");
-      goto end;
-    }
-  }
-
- end:
-  va_end(ap);
-  return 0;
-}
-
 int
 sandbox_cfg_allow_openat_filename(sandbox_cfg_t **cfg, char *file)
 {
@@ -1268,28 +1224,6 @@ sandbox_cfg_allow_openat_filename(sandbox_cfg_t **cfg, char *file)
   return 0;
 }
 
-int
-sandbox_cfg_allow_openat_filename_array(sandbox_cfg_t **cfg, ...)
-{
-  int rc = 0;
-  char *fn = NULL;
-
-  va_list ap;
-  va_start(ap, cfg);
-
-  while ((fn = va_arg(ap, char*)) != NULL) {
-    rc = sandbox_cfg_allow_openat_filename(cfg, fn);
-    if (rc) {
-      log_err(LD_BUG,"(Sandbox) sandbox_cfg_allow_openat_filename_array fail");
-      goto end;
-    }
-  }
-
- end:
-  va_end(ap);
-  return 0;
-}
-
 #if 0
 int
 sandbox_cfg_allow_execve(sandbox_cfg_t **cfg, const char *com)
@@ -1308,28 +1242,6 @@ sandbox_cfg_allow_execve(sandbox_cfg_t **cfg, const char *com)
   return 0;
 }
 
-int
-sandbox_cfg_allow_execve_array(sandbox_cfg_t **cfg, ...)
-{
-  int rc = 0;
-  char *fn = NULL;
-
-  va_list ap;
-  va_start(ap, cfg);
-
-  while ((fn = va_arg(ap, char*)) != NULL) {
-
-    rc = sandbox_cfg_allow_execve(cfg, fn);
-    if (rc) {
-      log_err(LD_BUG,"(Sandbox) sandbox_cfg_allow_execve_array failed");
-      goto end;
-    }
-  }
-
- end:
-  va_end(ap);
-  return 0;
-}
 #endif
 
 /** Cache entry for getaddrinfo results; used when sandboxing is implemented
index 26ce2183ed99824d6b3cf1ed1864f7b13a92db10..b4688bf9d83c390c149ec557686182eeb40b9b3b 100644 (file)
@@ -586,3 +586,4 @@ tor_zlib_get_total_allocation(void)
 {
   return total_zlib_allocation;
 }
+
index e04b4b93483b8a94a4d67be974fae64fbabb1204..35c52362d2caaecc9def98d395da33b0ecdc3c1a 100644 (file)
@@ -2083,7 +2083,6 @@ circuits_handle_oom(size_t current_allocation)
     circ->global_circuitlist_idx = circ_sl_idx;
   } SMARTLIST_FOREACH_END(circ);
 
-
   /* Now sort the connection array ... */
   now_ms_for_buf_cmp = now_ms;
   smartlist_sort(connection_array, conns_compare_by_buffer_age_);