This is the mail archive of the libc-alpha@sources.redhat.com mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Fetch week start value for gcal 3.01 from locale


[Petter Reinholdtsen]
> +  start_day = *nl_langinfo(_NL_TIME_FIRST_WEEKDAY) - 1 ;

The cal source in util-linux uses this notation to extract the week day:

  (int)nl_langinfo(_NL_TIME_FIRST_WEEKDAY)[0]

It might be a better alternative.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]