mirror of
https://github.com/ZoneMinder/zoneminder.git
synced 2026-03-19 06:18:15 -04:00
Now opens devices and shared memory read/write for v4l2 compatibility.
git-svn-id: http://svn.zoneminder.com/svn/zm/trunk@569 e3e1d417-86f3-4887-817a-d78f3d33393f
This commit is contained in:
@@ -52,21 +52,21 @@ bool fixDevice( int device )
|
||||
if ( uid == stat_buf.st_uid )
|
||||
{
|
||||
// If we are the owner
|
||||
mask = 00400;
|
||||
mask = 00600;
|
||||
}
|
||||
else if ( gid == stat_buf.st_gid )
|
||||
{
|
||||
// If we are in the owner group
|
||||
mask = 00040;
|
||||
mask = 00060;
|
||||
}
|
||||
else
|
||||
{
|
||||
// We are neither the owner nor in the group
|
||||
mask = 00004;
|
||||
mask = 00006;
|
||||
}
|
||||
|
||||
mode_t mode = stat_buf.st_mode;
|
||||
if ( mode & mask )
|
||||
if ( (mode & mask) == mask )
|
||||
{
|
||||
Info(( "Permissions on %s are ok at %o", device_path, mode ));
|
||||
return( true );
|
||||
|
||||
Reference in New Issue
Block a user