addr: Fix display for flags and scope
ip/addr.scm
186 | 186 | (format #t " brd ~a" brd)) | |
187 | 187 | (when scope | |
188 | 188 | (format #t " scope ~a" | |
189 | - | (match scope | |
190 | - | (RT_SCOPE_UNIVERSE "global") | |
191 | - | (_ (substring (symbol->string (int->rtm-scope scope)) 8))))) | |
189 | + | (cond | |
190 | + | ((equal? scope RT_SCOPE_UNIVERSE) "global") | |
191 | + | (else (string-downcase | |
192 | + | (substring (symbol->string (int->rtm-scope scope)) | |
193 | + | 9)))))) | |
192 | 194 | ||
193 | 195 | (for-each | |
194 | 196 | (lambda (flag) | |
195 | 197 | (unless (equal? flag 'IFA_F_PERMANENT) | |
196 | 198 | (format #t " ~a" | |
197 | - | (substring (symbol->string flag) 6)))) | |
199 | + | (string-downcase (substring (symbol->string flag) 6))))) | |
198 | 200 | flags) | |
199 | 201 | ||
200 | 202 | (when label |