diff options
author | Volker Lendecke <vl@samba.org> | 2008-01-20 13:55:27 +0100 |
---|---|---|
committer | Volker Lendecke <vl@samba.org> | 2008-01-20 13:55:27 +0100 |
commit | 4222fa62e927500f21f386ac57dd599234f7d8b1 (patch) | |
tree | 75f9739ce0366cb4e7674a3bb0b1d32047c96580 /source3 | |
parent | a39771d3d20280b289478da758089a1035415d65 (diff) | |
download | samba-4222fa62e927500f21f386ac57dd599234f7d8b1.tar.gz samba-4222fa62e927500f21f386ac57dd599234f7d8b1.tar.bz2 samba-4222fa62e927500f21f386ac57dd599234f7d8b1.zip |
Add some DEBUG
(This used to be commit 8db25aba63b1dffb0dfbc74012c7ebd0ce4d5682)
Diffstat (limited to 'source3')
-rw-r--r-- | source3/modules/vfs_streams_xattr.c | 12 | ||||
-rw-r--r-- | source3/modules/vfs_xattr_tdb.c | 6 |
2 files changed, 18 insertions, 0 deletions
diff --git a/source3/modules/vfs_streams_xattr.c b/source3/modules/vfs_streams_xattr.c index 7d7ec02fe7..e304810a02 100644 --- a/source3/modules/vfs_streams_xattr.c +++ b/source3/modules/vfs_streams_xattr.c @@ -92,6 +92,8 @@ static int streams_xattr_fstat(vfs_handle_struct *handle, files_struct *fsp, struct stream_io *io = (struct stream_io *) VFS_FETCH_FSP_EXTENSION(handle, fsp); + DEBUG(10, ("streams_xattr_fstat called for %d\n", fsp->fh->fd)); + if (io == NULL) { return SMB_VFS_NEXT_FSTAT(handle, fsp, sbuf); } @@ -105,6 +107,8 @@ static int streams_xattr_fstat(vfs_handle_struct *handle, files_struct *fsp, return -1; } + DEBUG(10, ("sbuf->st_size = %d\n", (int)sbuf->st_size)); + sbuf->st_ino = stream_inode(sbuf, io->xattr_name); sbuf->st_mode &= ~S_IFMT; sbuf->st_mode |= S_IFREG; @@ -219,6 +223,8 @@ static int streams_xattr_open(vfs_handle_struct *handle, const char *fname, int baseflags; int hostfd = -1; + DEBUG(10, ("streams_xattr_open called for %s\n", fname)); + if (!is_ntfs_stream_name(fname)) { return SMB_VFS_NEXT_OPEN(handle, fname, fsp, flags, mode); } @@ -267,6 +273,8 @@ static int streams_xattr_open(vfs_handle_struct *handle, const char *fname, status = get_ea_value(talloc_tos(), handle->conn, fsp, base, xattr_name, &ea); + DEBUG(10, ("get_ea_value returned %s\n", nt_errstr(status))); + if (!NT_STATUS_IS_OK(status) && !NT_STATUS_EQUAL(status, NT_STATUS_NOT_FOUND)) { /* @@ -274,6 +282,8 @@ static int streams_xattr_open(vfs_handle_struct *handle, const char *fname, * O_CREAT, the higher levels should have created the base * file for us. */ + DEBUG(10, ("streams_xattr_open: base file %s not around, " + "returning ENOENT\n", base)); errno = ENOENT; goto fail; } @@ -572,6 +582,8 @@ static ssize_t streams_xattr_pwrite(vfs_handle_struct *handle, NTSTATUS status; int ret; + DEBUG(10, ("streams_xattr_pwrite called for %d bytes\n", (int)n)); + if (sio == NULL) { return SMB_VFS_NEXT_PWRITE(handle, fsp, data, n, offset); } diff --git a/source3/modules/vfs_xattr_tdb.c b/source3/modules/vfs_xattr_tdb.c index 7416fa785a..208066bedc 100644 --- a/source3/modules/vfs_xattr_tdb.c +++ b/source3/modules/vfs_xattr_tdb.c @@ -165,6 +165,9 @@ static ssize_t xattr_tdb_getattr(struct db_context *db_ctx, ssize_t result = -1; NTSTATUS status; + DEBUG(10, ("xattr_tdb_getattr called for file %s, name %s\n", + file_id_string_tos(id), name)); + status = xattr_tdb_load_attrs(talloc_tos(), db_ctx, id, &attribs); if (!NT_STATUS_IS_OK(status)) { @@ -250,6 +253,9 @@ static int xattr_tdb_setattr(struct db_context *db_ctx, struct tdb_xattrs *attribs; uint32_t i; + DEBUG(10, ("xattr_tdb_setattr called for file %s, name %s\n", + file_id_string_tos(id), name)); + rec = xattr_tdb_lock_attrs(talloc_tos(), db_ctx, id); if (rec == NULL) { |