)]}'
{
  "commit": "390e2ff07712468ce6600a43aa91e897b056ce12",
  "tree": "fb92d3c2218fa3e41078d1b5e103892ac7e95117",
  "parents": [
    "9741ef964dc8bfeb6520825df9fed8f538c3336e"
  ],
  "author": {
    "name": "Eric W. Biederman",
    "email": "ebiederm@xmission.com",
    "time": "Fri Mar 31 02:31:33 2006 -0800"
  },
  "committer": {
    "name": "Linus Torvalds",
    "email": "torvalds@g5.osdl.org",
    "time": "Fri Mar 31 12:18:59 2006 -0800"
  },
  "message": "[PATCH] Make setsid() more robust\n\nThe core problem: setsid fails if it is called by init.  The effect in 2.6.16\nand the earlier kernels that have this problem is that if you do a \"ps -j 1 or\nps -ej 1\" you will see that init and several of it\u0027s children have process\ngroup and session \u003d\u003d 0.  Instead of process group \u003d\u003d session \u003d\u003d 1.  Despite\ninit calling setsid.\n\nThe reason it fails is that daemonize calls set_special_pids(1,1) on kernel\nthreads that are launched before /sbin/init is called.\n\nThe only remaining effect in that current-\u003esignal-\u003eleader \u003d\u003d 0 for init\ninstead of 1.  And the setsid call fails.  No one has noticed because\n/sbin/init does not check the return value of setsid.\n\nIn 2.4 where we don\u0027t have the pidhash table, and daemonize doesn\u0027t exist\nsetsid actually works for init.\n\nI care a lot about pid \u003d\u003d 1 not being a special case that we leave broken,\nbecause of the container/jail work that I am doing.\n\n- Carefully allow init (pid \u003d\u003d 1) to call setsid despite the kernel using\n  its session.\n\n- Use find_task_by_pid instead of find_pid because find_pid taking a\n  pidtype is going away.\n\nSigned-off-by: Eric W. Biederman \u003cebiederm@xmission.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@osdl.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@osdl.org\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "7ef7f6054c2851ac44d96e49eea4e55214fc0159",
      "old_mode": 33188,
      "old_path": "kernel/sys.c",
      "new_id": "0b6ec0e7936f02ebb92477dd12951169a2bc7218",
      "new_mode": 33188,
      "new_path": "kernel/sys.c"
    }
  ]
}
