mirror of
https://github.com/samba-team/samba.git
synced 2024-12-23 17:34:34 +03:00
smbstatus: add file_id information to byte-range locks in json output
Adds a dictionary with file_id information (devid, inode and extid) for each byte-range locked file. Signed-off-by: Jule Anger <janger@samba.org> Reviewed-by: Ralph Boehme <slow@samba.org>
This commit is contained in:
parent
c47d9d28f1
commit
fed1569f03
@ -412,6 +412,7 @@ static void print_brl(struct file_id id,
|
||||
} else {
|
||||
print_brl_json(state,
|
||||
pid,
|
||||
id,
|
||||
desc,
|
||||
lock_flav,
|
||||
(intmax_t)start,
|
||||
|
@ -1035,6 +1035,7 @@ failure:
|
||||
|
||||
int print_brl_json(struct traverse_state *state,
|
||||
const struct server_id server_id,
|
||||
struct file_id fid,
|
||||
const char *type,
|
||||
enum brl_flavour flavour,
|
||||
intmax_t start,
|
||||
@ -1070,6 +1071,10 @@ int print_brl_json(struct traverse_state *state,
|
||||
goto failure;
|
||||
}
|
||||
|
||||
result = add_fileid_to_json(&file_json, fid);
|
||||
if (result < 0) {
|
||||
goto failure;
|
||||
}
|
||||
result = json_add_string(&file_json, "file_name", filename);
|
||||
if (result < 0) {
|
||||
goto failure;
|
||||
|
@ -55,6 +55,7 @@ int print_share_mode_json(struct traverse_state *state,
|
||||
|
||||
int print_brl_json(struct traverse_state *state,
|
||||
const struct server_id server_id,
|
||||
struct file_id fid,
|
||||
const char *type,
|
||||
enum brl_flavour flavour,
|
||||
intmax_t start,
|
||||
|
@ -72,6 +72,7 @@ int print_share_mode_json(struct traverse_state *state,
|
||||
|
||||
int print_brl_json(struct traverse_state *state,
|
||||
const struct server_id server_id,
|
||||
struct file_id fid,
|
||||
const char *type,
|
||||
enum brl_flavour flavour,
|
||||
intmax_t start,
|
||||
|
Loading…
Reference in New Issue
Block a user