Skip to content

GUACAMOLE-2327: Report correct free space on large RDP redirected drives - #712

Merged
necouchman merged 1 commit into
apache:staging/1.6.1from
benjefferies:rdp-drive-64bit-capacity
Sep 14, 2026
Merged

necouchman merged 1 commit into
apache:staging/1.6.1from
benjefferies:rdp-drive-64bit-capacity

Conversation

@benjefferies

@benjefferies benjefferies commented Sep 9, 2026

Copy link
Copy Markdown
Contributor

Summary

Windows Explorer can report no free space on an RDP-redirected Guacamole drive when the backing filesystem is large, even though writes that skip Explorer's pre-copy check still succeed. Copies of new files then fail with an insufficient-space error.

guac_rdp_fs_info stored blocks_available and blocks_total as int. guac_rdp_fs_get_info() copies statvfs counts into those fields, and RDPDR later writes them as UINT64 (FileFsSizeInformation / FileFsFullSizeInformation). On filesystems with more than 2^31 allocation units, the 32-bit value overflows — often to zero — so Windows believes the drive is full.

What changed

  • Store the allocation-unit counts as uint64_t, matching the RDPDR reply already being sent.

Notes

Fixes: https://issues.apache.org/jira/browse/GUACAMOLE-2327

@benjefferies benjefferies changed the title Report correct free space on large RDP redirected drives GUACAMOLE-2327: Report correct free space on large RDP redirected drives Sep 10, 2026
@necouchman

Copy link
Copy Markdown
Contributor

@benjefferies Looks okay to me - can you rebase on staging/1.6.1?

@benjefferies
benjefferies changed the base branch from main to staging/1.6.1 September 14, 2026 15:49
@benjefferies
benjefferies force-pushed the rdp-drive-64bit-capacity branch from 4f2fe9c to 63dc06b Compare September 14, 2026 15:51
@benjefferies

Copy link
Copy Markdown
Contributor Author

Rebased onto staging/1.6.1 — the PR is now the single 64-bit guac_rdp_fs_info commit.

@benjefferies

Copy link
Copy Markdown
Contributor Author

All done @necouchman

@necouchman

Copy link
Copy Markdown
Contributor

Sorry @benjefferies, one other request - your commit message needs to be tagged with GUACAMOLE-2327, in addition to this pull request.

@cursor
cursor Bot force-pushed the rdp-drive-64bit-capacity branch from 63dc06b to 624c80b Compare September 14, 2026 16:55
RDPDR FileFsSizeInformation writes allocation-unit counts as UINT64,
but guac_rdp_fs_info stored them in a 32-bit int. Filesystems with
more than 2^31 allocation units then overflow, which can make Windows
report zero free space and refuse copies onto the redirected drive.

Related: GUACAMOLE-268, GUACAMOLE-764.
Co-authored-by: Cursor <cursoragent@cursor.com>
@cursor
cursor Bot force-pushed the rdp-drive-64bit-capacity branch from 624c80b to 50e24ff Compare September 14, 2026 17:01
@benjefferies

Copy link
Copy Markdown
Contributor Author

Update commit message

@necouchman
necouchman merged commit d9ec474 into apache:staging/1.6.1 Sep 14, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants