1*b52b1cd1Swiz.\" $NetBSD: printf_l.3,v 1.2 2016/12/29 20:29:30 wiz Exp $ 2841722beSchristos.\" Copyright (c) 2012 Isabell Long <issyl0@FreeBSD.org> 3841722beSchristos.\" All rights reserved. 4841722beSchristos.\" 5841722beSchristos.\" Redistribution and use in source and binary forms, with or without 6841722beSchristos.\" modification, are permitted provided that the following conditions 7841722beSchristos.\" are met: 8841722beSchristos.\" 1. Redistributions of source code must retain the above copyright 9841722beSchristos.\" notice, this list of conditions and the following disclaimer. 10841722beSchristos.\" 2. Redistributions in binary form must reproduce the above copyright 11841722beSchristos.\" notice, this list of conditions and the following disclaimer in the 12841722beSchristos.\" documentation and/or other materials provided with the distribution. 13841722beSchristos.\" 14841722beSchristos.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND 15841722beSchristos.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 16841722beSchristos.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 17841722beSchristos.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 18841722beSchristos.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 19841722beSchristos.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 20841722beSchristos.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 21841722beSchristos.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 22841722beSchristos.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 23841722beSchristos.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 24841722beSchristos.\" SUCH DAMAGE. 25841722beSchristos.\" 26841722beSchristos.\" $FreeBSD: head/lib/libc/stdio/printf_l.3 258245 2013-11-17 02:03:45Z eadler $ 27841722beSchristos.\" 28*b52b1cd1Swiz.Dd December 29, 2016 29841722beSchristos.Dt PRINTF_L 3 30841722beSchristos.Os 31841722beSchristos.Sh NAME 32841722beSchristos.Nm printf_l , 33841722beSchristos.Nm asprintf_l , 34841722beSchristos.Nm fprintf_l , 35841722beSchristos.Nm snprintf_l , 36841722beSchristos.Nm sprintf_l , 37841722beSchristos.Nm vasprintf_l , 38841722beSchristos.Nm vfprintf_l , 39841722beSchristos.Nm vprintf_l , 40841722beSchristos.Nm vsnprintf_l , 41841722beSchristos.Nm vsprintf_l 42841722beSchristos.Nd formatted output conversion 43841722beSchristos.Sh LIBRARY 44841722beSchristos.Lb libc 45841722beSchristos.Sh SYNOPSIS 46841722beSchristos.In stdio.h 47841722beSchristos.In locale.h 48841722beSchristos.Ft int 49841722beSchristos.Fn printf_l "locale_t loc" "const char * restrict format" "..." 50841722beSchristos.Ft int 51841722beSchristos.Fn asprintf_l "char **ret" "locale_t loc" "const char * format" "..." 52841722beSchristos.Ft int 53841722beSchristos.Fn fprintf_l "FILE * restrict stream" "locale_t loc" "const char * restrict format" "..." 54841722beSchristos.Ft int 55841722beSchristos.Fn snprintf_l "char * restrict str" "size_t size" "locale_t loc" "const char * restrict format" "..." 56841722beSchristos.Ft int 57841722beSchristos.Fn sprintf_l "char * restrict str" "locale_t loc" "const char * restrict format" "..." 58*b52b1cd1Swiz.In stdarg.h 59841722beSchristos.Ft int 60841722beSchristos.Fn vasprintf_l "char **ret" "locale_t loc" "const char *format" "va_list ap" 61841722beSchristos.Ft int 62841722beSchristos.Fn vfprintf_l "FILE * restrict stream" "locale_t loc" "const char * restrict format" "va_list ap" 63841722beSchristos.Ft int 64841722beSchristos.Fn vprintf_l "locale_t loc" "const char * restrict format" "va_list ap" 65841722beSchristos.Ft int 66841722beSchristos.Fn vsnprintf_l "char * restrict str" "size_t size" "locale_t loc" "const char * restrict format" "va_list ap" 67841722beSchristos.Ft int 68841722beSchristos.Fn vsprintf_l "char * restrict str" "locale_t loc" "const char * restrict format" "va_list ap" 69841722beSchristos.Sh DESCRIPTION 70841722beSchristosThe above functions are used to convert formatted output in the locale 71841722beSchristos.Fa loc . 72841722beSchristosThey behave in the same way as the versions without the _l suffix, but use 73841722beSchristosthe specified locale rather than the global or per-thread locale. 74841722beSchristosSee the specific manual pages for more information. 75841722beSchristos.Sh SEE ALSO 76841722beSchristos.Xr printf 3 , 77841722beSchristos.Xr xlocale 3 78841722beSchristos.Sh STANDARDS 79841722beSchristosThese functions do not conform to any specific standard so they should be 80841722beSchristosconsidered as non-portable local extensions. 81841722beSchristos.Sh HISTORY 82841722beSchristosThese functions first appeared in Darwin and were first implemented in 83841722beSchristos.Fx 9.1 84841722beSchristosand 85841722beSchristos.Nx 7 . 86