[lxc-devel] [lxc/lxc] d1838f: lxc.id_map bug when writing directly to /proc/pid/...

GitHub noreply at github.com
Thu Feb 6 05:35:03 UTC 2014


  Branch: refs/heads/master
  Home:   https://github.com/lxc/lxc
  Commit: d1838f34596635ca0684618a029cd691d8e3437d
      https://github.com/lxc/lxc/commit/d1838f34596635ca0684618a029cd691d8e3437d
  Author: Miquel van Smoorenburg <mikevs at xs4all.net>
  Date:   2014-02-05 (Wed, 05 Feb 2014)

  Changed paths:
    M src/lxc/conf.c

  Log Message:
  -----------
  lxc.id_map bug when writing directly to /proc/pid/[ug]id_map [PATCH]

lxc.id_map bug when writing directly to /proc/pid/[ug]id_map

There's some code in src/lxc/conf.c that sets up the UID/GID mapping. It
can use the external newuidmap/newgidmap tools, or it can write to
/proc/pid/[ug]id_map directly. The latter case is broken: lines are written
without a newline (\n) at the end. This patch fixes that. Note that
I did not check if the newuidmap/newgidmap case still works. It should,
but I wasn't able to test it.

Signed-off-by: Miquel van Smoorenburg <mikevs at xs4all.net>
Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>




More information about the lxc-devel mailing list