[PATCH] enable paths >260 for filelogs inside .hg on Windows (EXPERIMENTAL)
Matt Nordhoff
mnordhoff at mattnordhoff.com
Sun Jun 22 10:21:14 CDT 2008
Adrian Buehlmann wrote:
> Thanks for the tip!
>
> You're right, the hasattr call can be replaced by specifying
> None as a default for getattr.
>
> getattr raises AttributeError if no default is provided, so I
> think specifying None is needed in order to get to
Ah, sorry. I thought getattr() defaulted to None, not that it raised an
AttributeError. Oops.
>>> + size = util.fstat(fp).st_size
>
> when running on unix. Without the None, execution would go to
>
>>> size = 0
>
> wouldn't it ?
>
> However, if long path would have to be included in Mercurial, some
> refactoring would probably be needed anyway before mpm includes it.
> It was just the quickest thing I came up with during my quick-and-dirty
> experimenting.
--
More information about the Mercurial-devel
mailing list