MCPcopy Create free account
hub / github.com/OpenPrinting/cups / show_prompt

Function show_prompt

berkeley/lpc.c:209–226  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

207 */
208
209static void
210show_prompt(const char *message) /* I - Message string to use */
211{
212 ssize_t bytes; /* Number of bytes formatted */
213 char output[8192]; /* Message buffer */
214 cups_lang_t *lang = cupsLangDefault();
215 /* Default language */
216
217 /*
218 * Transcode to the destination charset and write the prompt...
219 */
220
221 if ((bytes = cupsUTF8ToCharset(output, (cups_utf8_t *)_cupsLangString(lang, message), sizeof(output), lang->encoding)) > 0)
222 {
223 fwrite(output, 1, (size_t)bytes, stdout);
224 fflush(stdout);
225 }
226}
227
228
229/*

Callers 1

mainFunction · 0.85

Calls 3

cupsLangDefaultFunction · 0.85
cupsUTF8ToCharsetFunction · 0.85
_cupsLangStringFunction · 0.85

Tested by

no test coverage detected