Author: brane
Date: Fri Jun 20 05:05:17 2025
New Revision: 1926593

URL: http://svn.apache.org/viewvc?rev=1926593&view=rev
Log:
Silence two more unused variable warnings.

* auth/auth_spnego.c (do_auth): Remove the unused 'authn_info' and 'ctx'.

* test/serf_httpd.c (main): root_dir was not used, but is a required
   argument, so use it to print a message.

Modified:
    serf/trunk/auth/auth_spnego.c
    serf/trunk/test/serf_httpd.c

Modified: serf/trunk/auth/auth_spnego.c
URL: 
http://svn.apache.org/viewvc/serf/trunk/auth/auth_spnego.c?rev=1926593&r1=1926592&r2=1926593&view=diff
==============================================================================
--- serf/trunk/auth/auth_spnego.c (original)
+++ serf/trunk/auth/auth_spnego.c Fri Jun 20 05:05:17 2025
@@ -261,20 +261,11 @@ do_auth(const serf__authn_scheme_t *sche
         const char *auth_hdr,
         apr_pool_t *pool)
 {
-    serf_context_t *ctx = conn->ctx;
-    serf__authn_info_t *authn_info;
     const char *tmp = NULL;
     char *token = NULL;
     apr_size_t tmp_len = 0, token_len = 0;
     apr_status_t status;
 
-    if (peer == HOST) {
-        authn_info = serf__get_authn_info_for_server(conn);
-    } else {
-        authn_info = &ctx->proxy_authn_info;
-    }
-    /* FIXME: authn_info's value is never used. */
-
     /* Is this a response from a host/proxy? auth_hdr should always be set. */
     if (code && auth_hdr) {
         const char *space = NULL;

Modified: serf/trunk/test/serf_httpd.c
URL: 
http://svn.apache.org/viewvc/serf/trunk/test/serf_httpd.c?rev=1926593&r1=1926592&r2=1926593&view=diff
==============================================================================
--- serf/trunk/test/serf_httpd.c (original)
+++ serf/trunk/test/serf_httpd.c Fri Jun 20 05:05:17 2025
@@ -383,6 +383,7 @@ int main(int argc, const char **argv)
     int verbose = 0;
     const char *opt_arg;
     const char *root_dir;
+    apr_finfo_t root_info;
 
     apr_initialize();
     atexit(apr_terminate);
@@ -448,8 +449,14 @@ int main(int argc, const char **argv)
         exit(-1);
     }
 
+    /* FIXME: root_dir is never used. */
     root_dir = argv[opt->ind];
-    /* FIXME: root_dir's value is never used. */
+    status = apr_stat(&root_info, root_dir, APR_FINFO_TYPE, scratch_pool);
+    printf("Ignoring root directory %s%s", root_dir,
+           (status == APR_SUCCESS
+            ? (root_info.filetype == APR_DIR ? "\n"
+               : " (which isn't a directory)\n")
+            : " (which doesn't even exist)\n"));
 
     /* Setup debug logging */
     if (verbose) {


Reply via email to