Commit Graph

12 Commits

Author SHA1 Message Date
Nalin Dahyabhai 5e67fd063f pkg/archive.statDifferent(): fix the previous change
Make the logic match the comment for real this time: instead of
comparing the datestamps a second time, check the ModeType bits.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
2024-06-12 10:21:48 -04:00
Nalin Dahyabhai 8182befdfd pkg/archive.statDifferent(): care about mtime for directories
When considering changes, don't ignore differences between directories
when their mtimes are the only thing we check that's changed.  This
creates a difference in behavior between the vfs and overlay drivers
that shows up in build conformance tests.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
2024-06-07 17:10:59 -04:00
Doug Rabson 2baf25d67c pkg/archive: Add support for detecting flag changes
Note: the Flags method of system.StatT always returns zero on
non-FreeBSD platforms so this should have no functional change for those
platforms.

Signed-off-by: Doug Rabson <dfr@rabson.org>
2022-10-20 08:58:04 +01:00
Daniel J Walsh 3dcbd58527
Coverity errors found
Fix leaked fd.
Fix potential dereference of nil.

Coverity found the leaked fd and the potential dereference.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2020-07-27 15:50:08 -04:00
Sascha Grunert fd72b45a3f
Enable golint linter and fix lints
Signed-off-by: Sascha Grunert <sgrunert@suse.com>
2020-01-28 15:59:15 +01:00
Nalin Dahyabhai 97326e1d2f Support for per-container uid/gid mapping: lower
Expose reading and writing ID mapping in the archive and chrootarchive
packages, and in the driver interface.  Generally this means that
when computing or applying diffs, we need to have ID mappings passed in
that are specific to the layers we're using.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
2018-04-03 10:34:32 -04:00
Daniel J Walsh f39066fe1b Update packages to match latest code in moby/pkg
Had to vendor in a new version of golang.org/x/net to build
Also had to make some changes to drivers to handle
archive.Reader -> io.Reader
archive.Archive -> io.ReadCloser

Also update .gitingore to ignore emacs files, containers-storage.*
and generated man pages.

Also no longer test travis against golang 1.7, cri-o, moby have also
done this.

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2017-09-12 18:00:29 +00:00
Nalin Dahyabhai 60ff079996 Rename: cow/cowman -> storage/oci-storage
Rename the library module and CLI wrapper.
Rename daemon/graphdriver to drivers.
Catch up vendoring to match modules we've pruned.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
2016-07-18 17:35:50 -04:00
Dmitry Vorobev 4102537cfd Fixes #9283. Consider hardlinks in image size.
Based on #8984. This patch fixes behavior when image size calculation
didn't consider hardlinks.

Signed-off-by: Dmitry Vorobev <dimahabr@gmail.com>
2015-10-17 12:24:05 +02:00
Phil Estes 79240b9eaf Correct mismatched function names (UID() and Gid())
All the go-lint work forced any existing "Uid" -> "UID", but seems to
not have the same rules for Gid, so stat package has calls UID() and
Gid().

Docker-DCO-1.1-Signed-off-by: Phil Estes <estesp@linux.vnet.ibm.com> (github: estesp)
2015-10-12 10:58:33 -04:00
Zhang Wei 7e420ad850 fix golint warnings/errors on `pkg/system` and `pkg/stdcopy`
Signed-off-by: Zhang Wei <zhangwei555@huawei.com>
2015-08-13 18:47:13 +08:00
John Howard 8228ee4b0f Windows: Archive package changes for Windows daemon
Signed-off-by: John Howard <jhoward@microsoft.com>
2015-05-20 08:55:54 -07:00