<feed xmlns='http://www.w3.org/2005/Atom'>
<title>gocryptfs/tests/test_helpers, branch xattr_user_buffer</title>
<subtitle>Mirror of gocryptfs source code on Github</subtitle>
<id>http://nuetzlich.net/cgit/gocryptfs/atom?h=xattr_user_buffer</id>
<link rel='self' href='http://nuetzlich.net/cgit/gocryptfs/atom?h=xattr_user_buffer'/>
<link rel='alternate' type='text/html' href='http://nuetzlich.net/cgit/gocryptfs/'/>
<updated>2025-07-08T17:54:14+00:00</updated>
<entry>
<title>Fix all staticcheck errors in gocryptfs codebase</title>
<updated>2025-07-08T17:54:14+00:00</updated>
<author>
<name>copilot-swe-agent[bot]</name>
</author>
<published>2025-07-07T18:18:12+00:00</published>
<link rel='alternate' type='text/html' href='http://nuetzlich.net/cgit/gocryptfs/commit/?id=386232f39ede046d6453a0990ad40f2d86a26f53'/>
<id>urn:sha1:386232f39ede046d6453a0990ad40f2d86a26f53</id>
<content type='text'>
Co-authored-by: rfjakob &lt;286847+rfjakob@users.noreply.github.com&gt;

Add staticcheck to test.bash for continuous static analysis

Co-authored-by: rfjakob &lt;286847+rfjakob@users.noreply.github.com&gt;

Fix nil pointer dereference in timesToTimespec function

The previous fix for deprecated fuse.UtimeToTimespec caused a panic
because unix.TimeToTimespec doesn't handle nil pointers. This fix
properly handles nil pointers by using unix.UTIME_OMIT while still
using the non-deprecated unix.TimeToTimespec function.

Co-authored-by: rfjakob &lt;286847+rfjakob@users.noreply.github.com&gt;

Undo SA6002 changes and add staticcheck ignore directive instead

Co-authored-by: rfjakob &lt;286847+rfjakob@users.noreply.github.com&gt;
</content>
</entry>
<entry>
<title>Fix a bunch of staticcheck errors</title>
<updated>2025-07-07T17:59:35+00:00</updated>
<author>
<name>Jakob Unterwurzacher</name>
</author>
<published>2025-07-07T17:54:48+00:00</published>
<link rel='alternate' type='text/html' href='http://nuetzlich.net/cgit/gocryptfs/commit/?id=8f5df19b353e02ffba842fd1b15ccf93da7ee3b4'/>
<id>urn:sha1:8f5df19b353e02ffba842fd1b15ccf93da7ee3b4</id>
<content type='text'>
Tool-assisted.
</content>
</entry>
<entry>
<title>tests: ignore pidfd in fd leak test</title>
<updated>2024-12-04T18:51:33+00:00</updated>
<author>
<name>Jakob Unterwurzacher</name>
</author>
<published>2024-12-04T18:51:33+00:00</published>
<link rel='alternate' type='text/html' href='http://nuetzlich.net/cgit/gocryptfs/commit/?id=9529f5da0f608c7dbc7b7be095d89039d6a3a5b6'/>
<id>urn:sha1:9529f5da0f608c7dbc7b7be095d89039d6a3a5b6</id>
<content type='text'>
This is not a real leak:

  fd leak in test process? before, after:
  [0r=/dev/null 3r=/proc/940141/fd 5rw=anon_inode:[eventfd] (filtered: pipe:[2454797], pipe:[2454797], anon_inode:[eventpoll])]
  [0r=/dev/null 3r=/proc/940141/fd 5rw=anon_inode:[eventfd] 12rw=anon_inode:[pidfd] (filtered: pipe:[2454797], pipe:[2454797], anon_inode:[eventpoll], pipe:[2460158])]

Ignore pidfd.
</content>
</entry>
<entry>
<title>make format</title>
<updated>2022-12-29T14:00:37+00:00</updated>
<author>
<name>Jakob Unterwurzacher</name>
</author>
<published>2022-12-29T14:00:24+00:00</published>
<link rel='alternate' type='text/html' href='http://nuetzlich.net/cgit/gocryptfs/commit/?id=856ccaac10579abda5620dfc86ad6031b1076a43'/>
<id>urn:sha1:856ccaac10579abda5620dfc86ad6031b1076a43</id>
<content type='text'>
Run "make format" using
go version go1.19.4 linux/amd64
</content>
</entry>
<entry>
<title>tests: enable -fusedebug if FUSEDEBUG env is set</title>
<updated>2022-01-22T10:46:08+00:00</updated>
<author>
<name>Jakob Unterwurzacher</name>
</author>
<published>2022-01-22T10:46:08+00:00</published>
<link rel='alternate' type='text/html' href='http://nuetzlich.net/cgit/gocryptfs/commit/?id=3ca2b1983dbab14e3769efd126098cbca6fb2ffd'/>
<id>urn:sha1:3ca2b1983dbab14e3769efd126098cbca6fb2ffd</id>
<content type='text'>
</content>
</entry>
<entry>
<title>go mod: declare module version v2</title>
<updated>2021-08-23T13:05:15+00:00</updated>
<author>
<name>Jakob Unterwurzacher</name>
</author>
<published>2021-08-23T13:05:15+00:00</published>
<link rel='alternate' type='text/html' href='http://nuetzlich.net/cgit/gocryptfs/commit/?id=69d88505fd7f4cb0d9e4f1918de296342fe05858'/>
<id>urn:sha1:69d88505fd7f4cb0d9e4f1918de296342fe05858</id>
<content type='text'>
Our git version is v2+ for some time now, but go.mod
still declared v1. Hopefully making both match makes
https://pkg.go.dev/github.com/rfjakob/gocryptfs/v2 work.

All the import paths have been fixed like this:

  find . -name \*.go | xargs sed -i s%github.com/rfjakob/gocryptfs/%github.com/rfjakob/gocryptfs/v2/%
</content>
</entry>
<entry>
<title>Implement -deterministic-names: extended -zerodiriv</title>
<updated>2021-08-20T08:58:42+00:00</updated>
<author>
<name>Jakob Unterwurzacher</name>
</author>
<published>2021-08-20T08:57:26+00:00</published>
<link rel='alternate' type='text/html' href='http://nuetzlich.net/cgit/gocryptfs/commit/?id=195d9d18a90d88ff2cb0530d832c59d98934fd1f'/>
<id>urn:sha1:195d9d18a90d88ff2cb0530d832c59d98934fd1f</id>
<content type='text'>
-deterministc-names uses all-zero dirivs but does not write
them to disk anymore.
</content>
</entry>
<entry>
<title>Flag -zerodiriv to create all diriv as all zero byte files</title>
<updated>2021-08-19T16:05:54+00:00</updated>
<author>
<name>Jose M Perez</name>
</author>
<published>2021-08-12T20:48:34+00:00</published>
<link rel='alternate' type='text/html' href='http://nuetzlich.net/cgit/gocryptfs/commit/?id=8f94083a2114c3aef4bc0320065e0374c420ea4a'/>
<id>urn:sha1:8f94083a2114c3aef4bc0320065e0374c420ea4a</id>
<content type='text'>
</content>
</entry>
<entry>
<title>test_helpers: actually use global testParentDir variable</title>
<updated>2021-08-19T06:34:49+00:00</updated>
<author>
<name>Jakob Unterwurzacher</name>
</author>
<published>2021-08-19T06:30:19+00:00</published>
<link rel='alternate' type='text/html' href='http://nuetzlich.net/cgit/gocryptfs/commit/?id=d8b8232c3c4fa309e11567f6fb42c9642dd9d24c'/>
<id>urn:sha1:d8b8232c3c4fa309e11567f6fb42c9642dd9d24c</id>
<content type='text'>
Typo inside doInit.
</content>
</entry>
<entry>
<title>golangci-lint: fix issues found by gosimple</title>
<updated>2021-08-19T06:34:44+00:00</updated>
<author>
<name>Jakob Unterwurzacher</name>
</author>
<published>2021-08-19T05:51:47+00:00</published>
<link rel='alternate' type='text/html' href='http://nuetzlich.net/cgit/gocryptfs/commit/?id=c86981342b46875525f2b214687553e23e58eb1a'/>
<id>urn:sha1:c86981342b46875525f2b214687553e23e58eb1a</id>
<content type='text'>
Everything except the

	if err2.Err == syscall.EOPNOTSUPP

case. Gets too confusing when collapsed into a single line.

Issues were:

$ golangci-lint run --disable-all --enable gosimple
mount.go:473:2: S1008: should use 'return strings.HasPrefix(v, "fusermount version")' instead of 'if strings.HasPrefix(v, "fusermount version") { return true }; return false' (gosimple)
	if strings.HasPrefix(v, "fusermount version") {
	^
cli_args.go:258:5: S1002: should omit comparison to bool constant, can be simplified to `args.forcedecode` (gosimple)
	if args.forcedecode == true {
	   ^
cli_args.go:263:6: S1002: should omit comparison to bool constant, can be simplified to `args.aessiv` (gosimple)
		if args.aessiv == true {
		   ^
cli_args.go:267:6: S1002: should omit comparison to bool constant, can be simplified to `args.reverse` (gosimple)
		if args.reverse == true {
		   ^
internal/stupidgcm/stupidgcm.go:227:6: S1002: should omit comparison to bool constant, can be simplified to `g.forceDecode` (gosimple)
		if g.forceDecode == true {
		   ^
gocryptfs-xray/xray_tests/xray_test.go:23:5: S1004: should use !bytes.Equal(out, expected) instead (gosimple)
	if bytes.Compare(out, expected) != 0 {
	   ^
gocryptfs-xray/xray_tests/xray_test.go:40:5: S1004: should use !bytes.Equal(out, expected) instead (gosimple)
	if bytes.Compare(out, expected) != 0 {
	   ^
gocryptfs-xray/paths_ctlsock.go:34:20: S1002: should omit comparison to bool constant, can be simplified to `!eof` (gosimple)
	for eof := false; eof == false; line++ {
	                  ^
tests/reverse/xattr_test.go:19:2: S1008: should use 'return err2.Err != syscall.EOPNOTSUPP' instead of 'if err2.Err == syscall.EOPNOTSUPP { return false }; return true' (gosimple)
	if err2.Err == syscall.EOPNOTSUPP {
	^
internal/fusefrontend/node.go:459:45: S1002: should omit comparison to bool constant, can be simplified to `!nameFileAlreadyThere` (gosimple)
		if nametransform.IsLongContent(cName2) &amp;&amp; nameFileAlreadyThere == false {
		                                          ^
tests/xattr/xattr_integration_test.go:221:2: S1008: should use 'return err2.Err != syscall.EOPNOTSUPP' instead of 'if err2.Err == syscall.EOPNOTSUPP { return false }; return true' (gosimple)
	if err2.Err == syscall.EOPNOTSUPP {
	^
tests/test_helpers/helpers.go:338:19: S1002: should omit comparison to bool constant, can be simplified to `open` (gosimple)
	if err != nil &amp;&amp; open == true {
	                 ^
tests/matrix/concurrency_test.go:121:7: S1004: should use !bytes.Equal(buf, content) instead (gosimple)
			if bytes.Compare(buf, content) != 0 {
			   ^
</content>
</entry>
</feed>
