~ruther/guix-local

a220b262dbeacb80d86af30d04d9f952616739d3 — Ludovic Courtès 10 years ago 2a5f0db
syscalls: 'all-network-interface-names' accepts non-alphanumeric characters.

This fixes interfaces with a dash or other characters being ignored.
Suggested by Jookia <166291@gmail.com>.

* guix/build/syscalls.scm (%interface-line): Use [[:graph:]] instead
of [[:alnum:]].
1 files changed, 2 insertions(+), 2 deletions(-)

M guix/build/syscalls.scm
M guix/build/syscalls.scm => guix/build/syscalls.scm +2 -2
@@ 1,5 1,5 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2014, 2015 Ludovic Courtès <ludo@gnu.org>
;;; Copyright © 2014, 2015, 2016 Ludovic Courtès <ludo@gnu.org>
;;; Copyright © 2015 David Thompson <davet@gnu.org>
;;;
;;; This file is part of GNU Guix.


@@ 625,7 625,7 @@ to interfaces that are currently up."

(define %interface-line
  ;; Regexp matching an interface line in Linux's /proc/net/dev.
  (make-regexp "^[[:blank:]]*([[:alnum:]]+):.*$"))
  (make-regexp "^[[:blank:]]*([[:graph:]]+):.*$"))

(define (all-network-interface-names)
  "Return all the names of the registered network interfaces, including those