On Wed, Nov 5, 2014 at 1:07 PM, Jakub Jelinek <ja...@redhat.com> wrote: > On Wed, Nov 05, 2014 at 12:48:01PM +0200, Janne Blomqvist wrote: >> @@ -3528,6 +3533,11 @@ finalize_transfer (st_parameter_dt *dtp) >> if ((dtp->common.flags & IOPARM_DT_HAS_SIZE) != 0) >> *dtp->size = dtp->u.p.size_used; >> >> +#ifdef HAVE_USELOCALE >> + if (dtp->u.p.old_locale != (locale_t) 0) >> + uselocale (dtp->u.p.old_locale); >> +#endif > > I wonder if you shouldn't clear dtp->u.p.old_locale here too, so > that uselocale isn't called again.
Sure. In principle this shouldn't be needed, since IIRC the entire dtp->u.p structure is set to 0 when starting an IO operation, but OTOH the cost is insignificant. -- Janne Blomqvist