Skip to content
Browse files

Ensure gids_num to be defined

  • Loading branch information...
1 parent 4525393 commit 147ec3efa3bb69a1e69d9888f9b8cbc2505172c2 @icy icy committed
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/god/process.rb
View
2 lib/god/process.rb
@@ -301,7 +301,7 @@ def spawn(command)
File.umask self.umask if self.umask
uid_num = Etc.getpwnam(self.uid).uid if self.uid
gid_num = Etc.getgrnam(self.gid).gid if self.gid
- gids_num = self.gids.map{|g| Etc.getgrnam(g).gid} if self.gids
+ gids_num = (self.gids || []).map{|g| Etc.getgrnam(g).gid}
::Dir.chroot(self.chroot) if self.chroot
::Process.setsid

0 comments on commit 147ec3e

Please sign in to comment.
Something went wrong with that request. Please try again.