summaryrefslogtreecommitdiff
path: root/source3/include
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>1998-10-24 08:08:05 +0000
committerAndrew Tridgell <tridge@samba.org>1998-10-24 08:08:05 +0000
commitfb556e14f3b47d5a1f465589084e8b30d84af8ca (patch)
tree90efd6b2e60d40552f23b481f08e69b5e9e24178 /source3/include
parent4140f2bfc141ee9a91723d274344769f8b11a5f9 (diff)
downloadsamba-fb556e14f3b47d5a1f465589084e8b30d84af8ca.tar.gz
samba-fb556e14f3b47d5a1f465589084e8b30d84af8ca.tar.bz2
samba-fb556e14f3b47d5a1f465589084e8b30d84af8ca.zip
volker was concerned about unique inode numbers and smbsh. This set of
changes uses the unique index number from a SMB_QUERY_FILE_ALL_INFO to try to provide inode numbers. If it is 0 then use the hash of the filename as before. (This used to be commit 2565ccf9de9d5e80fdb5bcadbc7130faba386d95)
Diffstat (limited to 'source3/include')
-rw-r--r--source3/include/client.h18
-rw-r--r--source3/include/includes.h6
-rw-r--r--source3/include/proto.h9
3 files changed, 21 insertions, 12 deletions
diff --git a/source3/include/client.h b/source3/include/client.h
index a393ee25a8..1caf78bf0e 100644
--- a/source3/include/client.h
+++ b/source3/include/client.h
@@ -35,15 +35,15 @@
typedef struct file_info
{
- SMB_OFF_T size;
- int mode;
- uid_t uid;
- gid_t gid;
- /* these times are normally kept in GMT */
- time_t mtime;
- time_t atime;
- time_t ctime;
- pstring name;
+ SMB_OFF_T size;
+ int mode;
+ uid_t uid;
+ gid_t gid;
+ /* these times are normally kept in GMT */
+ time_t mtime;
+ time_t atime;
+ time_t ctime;
+ pstring name;
} file_info;
struct print_job_info
diff --git a/source3/include/includes.h b/source3/include/includes.h
index 59d43d8a36..9d5ee28358 100644
--- a/source3/include/includes.h
+++ b/source3/include/includes.h
@@ -355,6 +355,12 @@
# endif
#endif
+#ifdef LARGE_SMB_INO_T
+#define SINO_T(p, ofs, v) (SIVAL(p,ofs,(v)&0xFFFFFFFF), SIVAL(p,(ofs)+4,(v)>>32))
+#else
+#define SINO_T(p, ofs, v) (SIVAL(p,ofs,v),SIVAL(p,(ofs)+4,0))
+#endif
+
#ifndef SMB_OFF_T
# ifdef HAVE_OFF64_T
# define SMB_OFF_T off64_t
diff --git a/source3/include/proto.h b/source3/include/proto.h
index bc9b7389db..1b81bb2038 100644
--- a/source3/include/proto.h
+++ b/source3/include/proto.h
@@ -407,10 +407,12 @@ BOOL cli_qpathinfo(struct cli_state *cli, const char *fname,
size_t *size, uint32 *mode);
BOOL cli_qpathinfo2(struct cli_state *cli, const char *fname,
time_t *c_time, time_t *a_time, time_t *m_time,
- time_t *w_time, size_t *size, uint32 *mode);
+ time_t *w_time, size_t *size, uint32 *mode,
+ SMB_INO_T *ino);
BOOL cli_qfileinfo(struct cli_state *cli, int fnum,
uint32 *mode, size_t *size,
- time_t *c_time, time_t *a_time, time_t *m_time);
+ time_t *c_time, time_t *a_time, time_t *m_time,
+ time_t *w_time, SMB_INO_T *ino);
int cli_list(struct cli_state *cli,char *Mask,int attribute,void (*fn)(file_info *));
BOOL cli_oem_change_password(struct cli_state *cli, char *user, char *new_password,
char *old_password);
@@ -2466,7 +2468,8 @@ off_t smbw_telldir(DIR *dirp);
void smbw_setup_stat(struct stat *st, char *fname, size_t size, int mode);
BOOL smbw_getatr(struct smbw_server *srv, char *path,
uint32 *mode, size_t *size,
- time_t *c_time, time_t *a_time, time_t *m_time);
+ time_t *c_time, time_t *a_time, time_t *m_time,
+ SMB_INO_T *ino);
int smbw_stat_printjob(struct smbw_server *srv,char *path,
size_t *size, time_t *m_time);
int smbw_fstat(int fd, struct stat *st);