Re: [PATCH v2 1/2] isofs: fix timestamps beyond 2027

2017-10-31 Thread Arnd Bergmann
On Tue, Oct 31, 2017 at 5:59 PM, Jan Kara wrote: > On Thu 19-10-17 17:29:12, Arnd Bergmann wrote: >> On Thu, Oct 19, 2017 at 5:17 PM, Jan Kara wrote: >> >> >> >> - year = p[0]; >> >> + year = (int)(u8)p[0]; >> > >> > The cast seems unnecessary now? >> > >> >>

Re: [PATCH v2 1/2] isofs: fix timestamps beyond 2027

2017-10-31 Thread Arnd Bergmann
On Tue, Oct 31, 2017 at 5:59 PM, Jan Kara wrote: > On Thu 19-10-17 17:29:12, Arnd Bergmann wrote: >> On Thu, Oct 19, 2017 at 5:17 PM, Jan Kara wrote: >> >> >> >> - year = p[0]; >> >> + year = (int)(u8)p[0]; >> > >> > The cast seems unnecessary now? >> > >> >> Sorry, I must have rebased

Re: [PATCH v2 1/2] isofs: fix timestamps beyond 2027

2017-10-31 Thread Jan Kara
On Thu 19-10-17 17:29:12, Arnd Bergmann wrote: > On Thu, Oct 19, 2017 at 5:17 PM, Jan Kara wrote: > > On Thu 19-10-17 16:47:48, Arnd Bergmann wrote: > >> isofs uses a 'char' variable to load the number of years since > >> 1900 for an inode timestamp. On architectures that use a

Re: [PATCH v2 1/2] isofs: fix timestamps beyond 2027

2017-10-31 Thread Jan Kara
On Thu 19-10-17 17:29:12, Arnd Bergmann wrote: > On Thu, Oct 19, 2017 at 5:17 PM, Jan Kara wrote: > > On Thu 19-10-17 16:47:48, Arnd Bergmann wrote: > >> isofs uses a 'char' variable to load the number of years since > >> 1900 for an inode timestamp. On architectures that use a signed > >> char

Re: [PATCH v2 1/2] isofs: fix timestamps beyond 2027

2017-10-19 Thread Arnd Bergmann
On Thu, Oct 19, 2017 at 5:17 PM, Jan Kara wrote: > On Thu 19-10-17 16:47:48, Arnd Bergmann wrote: >> isofs uses a 'char' variable to load the number of years since >> 1900 for an inode timestamp. On architectures that use a signed >> char type by default, this results in an invalid

Re: [PATCH v2 1/2] isofs: fix timestamps beyond 2027

2017-10-19 Thread Arnd Bergmann
On Thu, Oct 19, 2017 at 5:17 PM, Jan Kara wrote: > On Thu 19-10-17 16:47:48, Arnd Bergmann wrote: >> isofs uses a 'char' variable to load the number of years since >> 1900 for an inode timestamp. On architectures that use a signed >> char type by default, this results in an invalid date for >>

Re: [PATCH v2 1/2] isofs: fix timestamps beyond 2027

2017-10-19 Thread Jan Kara
On Thu 19-10-17 16:47:48, Arnd Bergmann wrote: > isofs uses a 'char' variable to load the number of years since > 1900 for an inode timestamp. On architectures that use a signed > char type by default, this results in an invalid date for > anything beyond 2027. > > This changes the function

Re: [PATCH v2 1/2] isofs: fix timestamps beyond 2027

2017-10-19 Thread Jan Kara
On Thu 19-10-17 16:47:48, Arnd Bergmann wrote: > isofs uses a 'char' variable to load the number of years since > 1900 for an inode timestamp. On architectures that use a signed > char type by default, this results in an invalid date for > anything beyond 2027. > > This changes the function

[PATCH v2 1/2] isofs: fix timestamps beyond 2027

2017-10-19 Thread Arnd Bergmann
isofs uses a 'char' variable to load the number of years since 1900 for an inode timestamp. On architectures that use a signed char type by default, this results in an invalid date for anything beyond 2027. This changes the function argument to a 'u8' array, which is defined the same way on all

[PATCH v2 1/2] isofs: fix timestamps beyond 2027

2017-10-19 Thread Arnd Bergmann
isofs uses a 'char' variable to load the number of years since 1900 for an inode timestamp. On architectures that use a signed char type by default, this results in an invalid date for anything beyond 2027. This changes the function argument to a 'u8' array, which is defined the same way on all