From ff6f53e925c49d9b5c21778a3fd890585389c79f Mon Sep 17 00:00:00 2001 From: yasuoka Date: Tue, 9 Sep 2025 04:15:53 +0000 Subject: [PATCH] Show a proper error when the specified address range cannot be added. diff from Yuichiro Naito --- usr.sbin/npppd/npppd/parse.y | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/usr.sbin/npppd/npppd/parse.y b/usr.sbin/npppd/npppd/parse.y index 4c1c894ce84..b2ae4117e66 100644 --- a/usr.sbin/npppd/npppd/parse.y +++ b/usr.sbin/npppd/npppd/parse.y @@ -1,4 +1,4 @@ -/* $OpenBSD: parse.y,v 1.31 2024/08/22 07:56:47 florian Exp $ */ +/* $OpenBSD: parse.y,v 1.32 2025/09/09 04:15:53 yasuoka Exp $ */ /* * Copyright (c) 2002, 2003, 2004 Henning Brauer @@ -875,14 +875,14 @@ ipcpopt : POOL_ADDRESS STRING ipcppooltype { if ($3 != 1) { if (in_addr_range_list_add( &curr_ipcpconf->dynamic_pool, $2) != 0) { - yyerror("out of memory"); + yyerror("%s", strerror(errno)); free($2); YYERROR; } } if (in_addr_range_list_add( &curr_ipcpconf->static_pool, $2) != 0) { - yyerror("out of memory"); + yyerror("%s", strerror(errno)); free($2); YYERROR; }