summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authornsayer <nsayer@FreeBSD.org>2000-07-11 15:04:05 +0000
committernsayer <nsayer@FreeBSD.org>2000-07-11 15:04:05 +0000
commitf0ebc4fdd1b7192a0123763205780f3fbbd3cd2f (patch)
tree32a13620a92a66d9ba321b57ce1d6af969085df9
parentec7724d85bc713696cc1dc02ea5d9dfcd6880c2a (diff)
downloadFreeBSD-src-f0ebc4fdd1b7192a0123763205780f3fbbd3cd2f.zip
FreeBSD-src-f0ebc4fdd1b7192a0123763205780f3fbbd3cd2f.tar.gz
Fix 'telnet -X sra' coredump
PR# 19835
-rw-r--r--contrib/telnet/libtelnet/auth.c4
-rw-r--r--crypto/telnet/libtelnet/auth.c4
2 files changed, 6 insertions, 2 deletions
diff --git a/contrib/telnet/libtelnet/auth.c b/contrib/telnet/libtelnet/auth.c
index d574b1e..8bdb2ca 100644
--- a/contrib/telnet/libtelnet/auth.c
+++ b/contrib/telnet/libtelnet/auth.c
@@ -29,6 +29,8 @@
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
+ *
+ * $FreeBSD$
*/
#ifndef lint
@@ -249,7 +251,7 @@ auth_disable_name(name)
{
int x;
for (x = 0; x < AUTHTYPE_CNT; ++x) {
- if (!strcasecmp(name, AUTHTYPE_NAME(x))) {
+ if (AUTHTYPE_NAME(x) && !strcasecmp(name, AUTHTYPE_NAME(x))) {
i_wont_support |= typemask(x);
break;
}
diff --git a/crypto/telnet/libtelnet/auth.c b/crypto/telnet/libtelnet/auth.c
index d574b1e..8bdb2ca 100644
--- a/crypto/telnet/libtelnet/auth.c
+++ b/crypto/telnet/libtelnet/auth.c
@@ -29,6 +29,8 @@
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
+ *
+ * $FreeBSD$
*/
#ifndef lint
@@ -249,7 +251,7 @@ auth_disable_name(name)
{
int x;
for (x = 0; x < AUTHTYPE_CNT; ++x) {
- if (!strcasecmp(name, AUTHTYPE_NAME(x))) {
+ if (AUTHTYPE_NAME(x) && !strcasecmp(name, AUTHTYPE_NAME(x))) {
i_wont_support |= typemask(x);
break;
}
OpenPOWER on IntegriCloud