Allow `NonBlockingPopen` not to fail badly and also not to block on MS Windows. Fixes #5969.
Try to narrow down used fds. Refs #5878.
Fix mode in salt.modules.file.mkdir()

This removes the last remaining octal-specific code from the file
module. Fixes #6033.
Merge pull request #6046 from terminalmage/issue6033

Fix mode in salt.modules.file.mkdir()
Merge pull request #6044 from s0undt3ch/issues/5878-file-descriptors-leak

Try to narrow down used fds. Refs #5878.
Bring back the master state function
Refine the master state systems
Fix issue with cp.get_dir copying more than intended

The get_dir member function of the salt fileclient was doing a simple
check to see if the path of a target file (or empty dir) started with
the specified salt:// path. As a result, salt://foo would match files
like salt://foo.sh or files within the directory salt://foobar/.

This commit adds a check to ensure that these undesired files/dirs are
not considered a match by the fileclient, and thus do not get
copied/replicated on the minion.

Fixes #6048.
Merge pull request #6047 from s0undt3ch/issues/5969-windows-non-blocking-reads

Allow `NonBlockingPopen` not to fail badly and also not to block on MS Windows
Merge pull request #6050 from terminalmage/issue6048

Fix issue with cp.get_dir copying more than intended