From patchwork Tue Jul 15 15:09:27 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Dickson X-Patchwork-Id: 4554741 Return-Path: X-Original-To: patchwork-linux-nfs@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 7158AC0514 for ; Tue, 15 Jul 2014 15:10:12 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id A7E3C2015E for ; Tue, 15 Jul 2014 15:10:11 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id D6ACA2012B for ; Tue, 15 Jul 2014 15:10:10 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754362AbaGOPJx (ORCPT ); Tue, 15 Jul 2014 11:09:53 -0400 Received: from mx1.redhat.com ([209.132.183.28]:32695 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753990AbaGOPJs (ORCPT ); Tue, 15 Jul 2014 11:09:48 -0400 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id s6FF9fVS017563 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 15 Jul 2014 11:09:41 -0400 Received: from smallhat.boston.devel.redhat.com (smallhat.boston.devel.redhat.com [10.19.60.65]) by int-mx10.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id s6FF9ahU009793; Tue, 15 Jul 2014 11:09:40 -0400 From: Steve Dickson To: Libtirpc-devel Mailing List Cc: Linux NFS Mailing list Subject: [PATCH 08/15] print_rpc_gss_sec: Make sure logging to stderr is enabled. Date: Tue, 15 Jul 2014 11:09:27 -0400 Message-Id: <1405436974-4161-9-git-send-email-steved@redhat.com> In-Reply-To: <1405436974-4161-1-git-send-email-steved@redhat.com> References: <1405436974-4161-1-git-send-email-steved@redhat.com> X-Scanned-By: MIMEDefang 2.68 on 10.5.11.23 Sender: linux-nfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP It does not make sense to try an covert this routine to used the new debugging macro. So just insure the correct debugging level and logging to stderr is enabled. Signed-off-by: Steve Dickson --- src/auth_gss.c | 3 +++ src/authgss_prot.c | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/auth_gss.c b/src/auth_gss.c index e636e7e..d8d5a72 100644 --- a/src/auth_gss.c +++ b/src/auth_gss.c @@ -88,6 +88,9 @@ print_rpc_gss_sec(struct rpc_gss_sec *ptr) int i; char *p; + if (libtirpc_debug_level < 4 || log_stderr == 0) + return; + gss_log_debug("rpc_gss_sec:"); if(ptr->mech == NULL) gss_log_debug("NULL gss_OID mech"); diff --git a/src/authgss_prot.c b/src/authgss_prot.c index 6dc4af6..669eab7 100644 --- a/src/authgss_prot.c +++ b/src/authgss_prot.c @@ -338,7 +338,7 @@ gss_log_hexdump(const u_char *buf, int len, int offset) u_int i, j, jm; int c; - if (libtirpc_debug_level < 3 || log_stderr == 0) + if (libtirpc_debug_level < 4 || log_stderr == 0) return; fprintf(stderr, "\n");