]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
Fix minor typos, two line lengths, and a repeated include
authorteor <teor2345@gmail.com>
Wed, 22 Oct 2014 15:35:46 +0000 (02:35 +1100)
committerteor <teor2345@gmail.com>
Wed, 22 Oct 2014 15:57:11 +0000 (02:57 +1100)
src/common/address.c
src/common/compat.c
src/common/log.c
src/or/buffers.c
src/test/test_socks.c

index 07b76597dab5dd3a920eb6276e2716774a450f6b..20f4d14dddc63f2f8b71658eed1b557f9f5ab20a 100644 (file)
@@ -883,7 +883,7 @@ tor_addr_copy(tor_addr_t *dest, const tor_addr_t *src)
   memcpy(dest, src, sizeof(tor_addr_t));
 }
 
-/** Copy a tor_addr_t from <b>src</b> to <b>dest</b>, taking extra case to
+/** Copy a tor_addr_t from <b>src</b> to <b>dest</b>, taking extra care to
  * copy only the well-defined portions. Used for computing hashes of
  * addresses.
  */
index b6fdb1ad787626579cd66a05ae5edefa2afd9fdd..0f9f4fadc3a94f24fe6c8f2c37d45520f7f58185 100644 (file)
@@ -77,6 +77,7 @@
 
 /* Includes for the process attaching prevention */
 #if defined(HAVE_SYS_PRCTL_H) && defined(__linux__)
+/* Only use the linux prctl;  the IRIX prctl is totally different */
 #include <sys/prctl.h>
 #elif defined(__APPLE__)
 #include <sys/types.h>
 #ifdef HAVE_SYS_FILE_H
 #include <sys/file.h>
 #endif
-#if defined(HAVE_SYS_PRCTL_H) && defined(__linux__)
-/* Only use the linux prctl;  the IRIX prctl is totally different */
-#include <sys/prctl.h>
-#endif
 #ifdef TOR_UNIT_TESTS
 #if !defined(HAVE_USLEEP) && defined(HAVE_SYS_SELECT_H)
 /* as fallback implementation for tor_sleep_msec */
@@ -2883,7 +2880,7 @@ tor_localtime_r(const time_t *timep, struct tm *result)
 /** @} */
 
 /** @{ */
-/** As gmtimee_r, but defined for platforms that don't have it:
+/** As gmtime_r, but defined for platforms that don't have it:
  *
  * Convert *<b>timep</b> to a struct tm in UTC, and store the value in
  * *<b>result</b>.  Return the result on success, or NULL on failure.
index 4b3817780bd4deabd210ed148e75fcedaa1174d4..6bdc332e5cac28a7c4971a134d6c5fcc8c86a985 100644 (file)
@@ -371,8 +371,8 @@ pending_log_message_free(pending_log_message_t *msg)
   tor_free(msg);
 }
 
-/** Return true iff <b>lf</b> would like to receive a message with the specified
- * <b>severity</b> in the specified <b>domain</b>.
+/** Return true iff <b>lf</b> would like to receive a message with the
+ * specified <b>severity</b> in the specified <b>domain</b>.
  */
 static INLINE int
 logfile_wants_message(const logfile_t *lf, int severity,
index 9f02824bff18b6157581bc11769fc44c6325ea7e..b415c8f084c13ab82cc4f5595b4c7414cc55faab 100644 (file)
@@ -1912,7 +1912,7 @@ parse_socks(const char *data, size_t datalen, socks_request_t *req,
       }
       *drain_out = 2u + usernamelen + 1u + passlen;
       req->got_auth = 1;
-      *want_length_out = 7; /* Minimal socks5 sommand. */
+      *want_length_out = 7; /* Minimal socks5 command. */
       return 0;
     } else if (req->auth_type == SOCKS_USER_PASS) {
       /* unknown version byte */
index 9aaa16e081f1e748453bd3382978ed14957666f9..dea5f52b8b40c8b1d229c49c81f5625799b6f274 100644 (file)
@@ -392,7 +392,8 @@ test_socks_5_malformed_commands(void *ptr)
 
   /* XXX: Stringified address length > MAX_SOCKS_ADDR_LEN will never happen */
 
-  /* SOCKS 5 Send CONNECT [01] to IP address 2.2.2.2:4369, with SafeSocks set */
+  /** SOCKS 5 Send CONNECT [01] to IP address 2.2.2.2:4369, with SafeSocks set
+   */
   ADD_DATA(buf, "\x05\x01\x00");
   ADD_DATA(buf, "\x05\x01\x00\x01\x02\x02\x02\x02\x11\x11");
   tt_int_op(fetch_from_buf_socks(buf, socks, get_options()->TestSocks, 1),==,