diff mbox series

[45/90] ipconfig: Use 'RT_SCOPE_*' mnemonics.

Message ID 20231206235056.322578-49-gerickson@nuovations.com (mailing list archive)
State Not Applicable, archived
Headers show
Series Add Gateway Low-priority Default Routes for Non-default Services | expand

Commit Message

Grant Erickson Dec. 6, 2023, 11:50 p.m. UTC
From: Grant Erickson <erick205@umn.edu>

This leverages 'RT_SCOPE_*' mnemonics rather than magic numbers for
'scope2str'.
---
 src/ipconfig.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/src/ipconfig.c b/src/ipconfig.c
index 55a05694ff14..e26fc13799fb 100644
--- a/src/ipconfig.c
+++ b/src/ipconfig.c
@@ -263,9 +263,9 @@  static const char *type2str(unsigned short type)
 static const char *scope2str(unsigned char scope)
 {
 	switch (scope) {
-	case 0:
+	case RT_SCOPE_UNIVERSE:
 		return "UNIVERSE";
-	case 253:
+	case RT_SCOPE_LINK:
 		return "LINK";
 	}