Skip to content

Conversation

@icewind1991
Copy link
Member

When uploading a file with an mtime in the future the parent folders also get the future timestamp.

This clamps the propagated mtime to the current one to prevent this.

to test:

  • create a local file with a timestamp in the future: touch -d "now +1 year" test.txt
  • Create a folder test
  • Upload test.txt into the test folder
  • Check the mtime of the test folder

@icewind1991 icewind1991 added the 3. to review Waiting for reviews label Nov 28, 2024
@icewind1991 icewind1991 added this to the Nextcloud 31 milestone Nov 28, 2024
@icewind1991 icewind1991 requested review from a team, Altahrim, ArtificialOwl and provokateurin and removed request for a team November 28, 2024 15:55
@icewind1991 icewind1991 force-pushed the dont-propagate-future-time branch from 3e42229 to 86719a8 Compare November 28, 2024 15:57
@icewind1991 icewind1991 force-pushed the dont-propagate-future-time branch from 86719a8 to d41983f Compare November 28, 2024 16:13
@icewind1991
Copy link
Member Author

reverted the constructor argument changes, was causing to much splash damage

@icewind1991 icewind1991 force-pushed the dont-propagate-future-time branch from d41983f to 8c7bd01 Compare November 28, 2024 16:19
@icewind1991
Copy link
Member Author

/backport to stable30

@icewind1991
Copy link
Member Author

/backport to stable29

@icewind1991 icewind1991 force-pushed the dont-propagate-future-time branch from 8c7bd01 to aadfcb3 Compare November 28, 2024 16:24
@Altahrim
Copy link
Collaborator

reverted the constructor argument changes, was causing to much splash damage

I didn't saw the "splash", do you think we could backport this and add clock in constructor for master?

@bricewge bricewge mentioned this pull request Dec 4, 2024
9 tasks
@skjnldsv skjnldsv merged commit b4c43bb into master Dec 4, 2024
187 checks passed
@skjnldsv skjnldsv deleted the dont-propagate-future-time branch December 4, 2024 19:11
@skjnldsv skjnldsv mentioned this pull request Jan 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3. to review Waiting for reviews

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants