Skip to contentSkip to conversation

cifs/002: check nlink returned by fstat()

RFC PATCH New ChenXiaoSong 1 participant 1 message Jul 10

Subsystems (2)
lore
Share & tools
lore

ChenXiaoSong

author reviewer
#0 lore raw

RFC PATCH 1/1 cifs/002: check nlink returned by fstat()

From: ChenXiaoSong <[email protected]>

Add a CIFS test based on generic/002 to verify that fstat(2) returns the expected st_nlink value as hardlinks are created and removed.

---
 src/Makefile       |   2 +-
 src/fstat.c        | 200 +++++++++++++++++++++++++++++++++++++++++++++
 tests/cifs/002     |  61 ++++++++++++++
 tests/cifs/002.out |   2 +
 4 files changed, 264 insertions(+), 1 deletion(-)
 create mode 100644 src/fstat.c
 create mode 100755 tests/cifs/002
 create mode 100644 tests/cifs/002.out
src/Makefile +1 -1
index 31ac43b2..b0886279 100644
@@ -6,7 +6,7 @@
 TOPDIR = ..
 include $(TOPDIR)/include/builddefs
 
-TARGETS = dirstress fill fill2 getpagesize holes lstat64 \
+TARGETS = dirstress fill fill2 getpagesize holes lstat64 fstat \
 	nametest permname randholes runas truncfile usemem \
 	mmapcat append_reader append_writer dirperf metaperf \
 	devzero feature alloc fault fstest t_access_root \
src/fstat.c new file +200 -0

200 lines not on this page · raw message

tests/cifs/002 new file +61 -0

61 lines not on this page · raw message

tests/cifs/002.out new file +2 -0
new file mode 100644
index 00000000..11426b54
@@ -0,0 +1,2 @@
+QA output created by 002
+Silence is goodness ...
Signature · 1 line
2.43.0