FreeBSD: Define crgetzoneid appropriately

The previous ZFS implementation on FreeBSD had ifdefs to use jailed()
instead of crgetzoneid() in dsl_dir.c, however we can simply provide an
appropriate definition of crgetzoneid for the same effect.

Reviewed-by: Alexander Motin <mav@FreeBSD.org>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ryan Moeller <freqlabs@FreeBSD.org>
Closes #10851
This commit is contained in:
Ryan Moeller 2020-08-29 18:25:56 +00:00 committed by Brian Behlendorf
parent 1144586b57
commit 2f65c7a608
1 changed files with 1 additions and 1 deletions

View File

@ -93,7 +93,7 @@ extern cred_t *zone_kcred(void);
extern gid_t crgetrgid(const cred_t *); extern gid_t crgetrgid(const cred_t *);
extern gid_t crgetsgid(const cred_t *); extern gid_t crgetsgid(const cred_t *);
#define crgetzoneid(x) (0) #define crgetzoneid(cr) ((cr)->cr_prison->pr_id)
extern projid_t crgetprojid(const cred_t *); extern projid_t crgetprojid(const cred_t *);
extern cred_t *crgetmapped(const cred_t *); extern cred_t *crgetmapped(const cred_t *);