trafficserver-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From zw...@apache.org
Subject [1/4] git commit: TS-1079 Minor identation and style changes.
Date Mon, 09 Apr 2012 21:28:14 GMT
Updated Branches:
  refs/heads/master 12ce45131 -> 59f30287a


TS-1079 Minor identation and style changes.


Project: http://git-wip-us.apache.org/repos/asf/trafficserver/repo
Commit: http://git-wip-us.apache.org/repos/asf/trafficserver/commit/59f30287
Tree: http://git-wip-us.apache.org/repos/asf/trafficserver/tree/59f30287
Diff: http://git-wip-us.apache.org/repos/asf/trafficserver/diff/59f30287

Branch: refs/heads/master
Commit: 59f30287acb9528e2a1bfe17c3a8c3c0a5982dc2
Parents: abf767e
Author: Leif Hedstrom <zwoop@apache.org>
Authored: Thu Apr 5 16:40:46 2012 -0600
Committer: Leif Hedstrom <zwoop@apache.org>
Committed: Mon Apr 9 15:01:19 2012 -0600

----------------------------------------------------------------------
 proxy/InkAPI.cc            |   27 +++++++++++++--------------
 proxy/api/ts/ts.h.in       |   32 ++++++++++++++++----------------
 proxy/http/HttpTransact.cc |   14 +++++++-------
 3 files changed, 36 insertions(+), 37 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/trafficserver/blob/59f30287/proxy/InkAPI.cc
----------------------------------------------------------------------
diff --git a/proxy/InkAPI.cc b/proxy/InkAPI.cc
index 82974e9..0cb4eb1 100644
--- a/proxy/InkAPI.cc
+++ b/proxy/InkAPI.cc
@@ -5753,27 +5753,27 @@ TSHttpTxnServerStateGet(TSHttpTxn txnp)
 void
 TSHttpTxnDebugSet(TSHttpTxn txnp, int on)
 {
-    sdk_assert(sdk_sanity_check_txn(txnp) == TS_SUCCESS);
-    ((HttpSM *)txnp)->debug_on = on;
+  sdk_assert(sdk_sanity_check_txn(txnp) == TS_SUCCESS);
+  ((HttpSM *)txnp)->debug_on = on;
 }
 
 int
 TSHttpTxnDebugGet(TSHttpTxn txnp)
 {
-    sdk_assert(sdk_sanity_check_txn(txnp) == TS_SUCCESS);
-    return ((HttpSM *)txnp)->debug_on;
+  sdk_assert(sdk_sanity_check_txn(txnp) == TS_SUCCESS);
+  return ((HttpSM *)txnp)->debug_on;
 }
 void
 TSHttpSsnDebugSet(TSHttpSsn ssnp, int on)
 {
-    sdk_assert(sdk_sanity_check_http_ssn(ssnp) == TS_SUCCESS);
-    ((HttpClientSession *)ssnp)->debug_on = on;
+  sdk_assert(sdk_sanity_check_http_ssn(ssnp) == TS_SUCCESS);
+  ((HttpClientSession *)ssnp)->debug_on = on;
 }
 int
 TSHttpSsnDebugGet(TSHttpSsn ssnp)
 {
-    sdk_assert(sdk_sanity_check_http_ssn(ssnp) == TS_SUCCESS);
-    return ((HttpClientSession *)ssnp)->debug_on;
+  sdk_assert(sdk_sanity_check_http_ssn(ssnp) == TS_SUCCESS);
+  return ((HttpClientSession *)ssnp)->debug_on;
 }
 
 int
@@ -6880,13 +6880,12 @@ TSIsDebugTagSet(const char *t)
 void
 TSDebugSpecific(int debug_flag, const char *tag, const char *format_str, ...)
 {
-  if (diags->on(tag, DiagsTagType_Debug) ||
-      (debug_flag  && diags->on())) {
+  if (diags->on(tag, DiagsTagType_Debug) || (debug_flag  && diags->on())) {
+    va_list ap;
 
-      va_list ap;
-      va_start(ap, format_str);
-      diags->print_va(tag, DL_Diag, NULL, format_str, ap);
-      va_end(ap);
+    va_start(ap, format_str);
+    diags->print_va(tag, DL_Diag, NULL, format_str, ap);
+    va_end(ap);
   }
 }
 

http://git-wip-us.apache.org/repos/asf/trafficserver/blob/59f30287/proxy/api/ts/ts.h.in
----------------------------------------------------------------------
diff --git a/proxy/api/ts/ts.h.in b/proxy/api/ts/ts.h.in
index 38e024d..b0744bd 100644
--- a/proxy/api/ts/ts.h.in
+++ b/proxy/api/ts/ts.h.in
@@ -2357,41 +2357,41 @@ extern "C"
   tsapi void TSHttpTxnNoActivityTimeoutSet(TSHttpTxn txnp, int timeout);
 
   tsapi TSServerState TSHttpTxnServerStateGet(TSHttpTxn txnp);
-  
+
   /* --------------------------------------------------------------------------
      Transaction specific debugging control  */
-     
+
   /**
          Set the transaction specific debugging flag for this transaction.
          When turned on, internal debug messeges related to this transaction
          will be written even if the debug tag isn't on.
-             
+
       @param txnp transaction to change.
       @param on set to 1 to turn on, 0 to turn off.
   */
   tsapi void TSHttpTxnDebugSet(TSHttpTxn txnp, int on);
   /**
          Returns the transaction specific debugging flag for this transaction.
-             
+
       @param txnp transaction to check.
-      @return 1 if enabled, 0 otherwise. 
-  */ 
+      @return 1 if enabled, 0 otherwise.
+  */
   tsapi int TSHttpTxnDebugGet(TSHttpTxn txnp);
   /**
          Set the session specific debugging flag for this client session.
          When turned on, internal debug messeges related to this session and all transactions
          in the session will be written even if the debug tag isn't on.
-             
+
       @param ssnp Client session to change.
       @param on set to 1 to turn on, 0 to turn off.
   */
   tsapi void TSHttpSsnDebugSet(TSHttpSsn ssnp, int on);
   /**
          Returns the transaction specific debugging flag for this client session.
-             
+
       @param txnp Client session to check.
-      @return 1 if enabled, 0 otherwise. 
-  */ 
+      @return 1 if enabled, 0 otherwise.
+  */
   tsapi int TSHttpSsnDebugGet(TSHttpSsn ssnp, int *on);
 
   /* --------------------------------------------------------------------------
@@ -2473,7 +2473,7 @@ extern "C"
 
    */
   tsapi TSVConn TSHttpConnect(struct sockaddr const* addr);
-  
+
     /* --------------------------------------------------------------------------
      Initiate Transparent Http Connection */
   /**
@@ -2486,10 +2486,10 @@ extern "C"
       @param server_addr the address that the resulting connection will be seen as
       	attempting to connect to when intercepted
       @param vc will be set to point to the new TSVConn on success.
-      
+
    */
   tsapi TSVConn TSHttpConnectTransparent(struct sockaddr const* client_addr, struct sockaddr
const * server_addr);
-  
+
   tsapi void TSFetchUrl(const char* request,int request_len, struct sockaddr const* addr,
TSCont contp, TSFetchWakeUpOptions callback_options,TSFetchEvent event);
   tsapi void TSFetchPages(TSFetchUrlParams_t* params);
 
@@ -2883,12 +2883,12 @@ extern "C"
   tsapi int TSIsDebugTagSet(const char* t);
   tsapi void TSDebug(const char* tag, const char* format_str, ...) TS_PRINTFLIKE(2, 3);
   /**
-      Output a debug line even if the debug tag is turned off, as long as 
-      debugging is enabled. Could be used as follows: 
+      Output a debug line even if the debug tag is turned off, as long as
+      debugging is enabled. Could be used as follows:
       @code
       TSDebugSpecifc(TSHttpTxnDebugGet(txn), "plugin_tag" , "Hello World from transaction
%p", txn);
       @endcode
-      will be printed if the plugin_tag is enabled or the transaction specific 
+      will be printed if the plugin_tag is enabled or the transaction specific
       debugging is turned on for txn.
 
       @param debug_flag boolean flag.

http://git-wip-us.apache.org/repos/asf/trafficserver/blob/59f30287/proxy/http/HttpTransact.cc
----------------------------------------------------------------------
diff --git a/proxy/http/HttpTransact.cc b/proxy/http/HttpTransact.cc
index feec272..3d8fe40 100644
--- a/proxy/http/HttpTransact.cc
+++ b/proxy/http/HttpTransact.cc
@@ -880,8 +880,8 @@ HttpTransact::EndRemapRequest(State* s)
     // check for: (1) reverse proxy is on, and no URL host //
     /////////////////////////////////////////////////////////
     if (s->http_config_param->reverse_proxy_enabled
-	&& !s->client_info.is_transparent
-	&& !incoming_request->is_target_in_url()) {
+        && !s->client_info.is_transparent
+        && !incoming_request->is_target_in_url()) {
       /////////////////////////////////////////////////////////
       // the url mapping failed, reverse proxy was enabled,
       // and the request contains no host:
@@ -1780,12 +1780,12 @@ HttpTransact::DecideCacheLookup(State* s)
         s->cache_info.lookup_url_storage.create(NULL);
         s->cache_info.lookup_url_storage.copy(incoming_request->url_get());
         s->cache_info.lookup_url = &s->cache_info.lookup_url_storage;
-	// if the target isn't in the URL, put it in the copy for
-	// cache lookup.
-	incoming_request->set_url_target_from_host_field(s->cache_info.lookup_url);
+        // if the target isn't in the URL, put it in the copy for
+        // cache lookup.
+        incoming_request->set_url_target_from_host_field(s->cache_info.lookup_url);
       } else {
-	// make sure the target is in the URL.
-	incoming_request->set_url_target_from_host_field();
+        // make sure the target is in the URL.
+        incoming_request->set_url_target_from_host_field();
         s->cache_info.lookup_url = incoming_request->url_get();
       }
 


Mime
View raw message