w32tex
About: TeX Live provides a comprehensive TeX system including all the major TeX-related programs, macro packages, and fonts that are free software. Windows sources.
  Fossies Dox: w32tex-src.tar.xz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

cff.cc
Go to the documentation of this file.
1 // -*- related-file-name: "../include/efont/cff.hh" -*-
2 
3 /* cff.{cc,hh} -- Compact Font Format fonts
4  *
5  * Copyright (c) 1998-2019 Eddie Kohler
6  *
7  * This program is free software; you can redistribute it and/or modify it
8  * under the terms of the GNU General Public License as published by the Free
9  * Software Foundation; either version 2 of the License, or (at your option)
10  * any later version. This program is distributed in the hope that it will be
11  * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
13  * Public License for more details.
14  */
15 
16 #ifdef HAVE_CONFIG_H
17 # include <config.h>
18 #endif
19 #include <efont/cff.hh>
20 #include <lcdf/error.hh>
21 #include <efont/t1item.hh>
22 #include <lcdf/straccum.hh>
23 #include <errno.h>
24 #include <stdlib.h>
25 #include <string.h>
26 #include <math.h>
27 #include <ctype.h>
28 #include <efont/t1unparser.hh>
29 
30 #ifndef static_assert
31 #define static_assert(c, msg) switch ((int) (c)) case 0: case (c):
32 #endif
33 
34 namespace Efont {
35 
36 const char * const Cff::operator_names[] = {
37  "version", "Notice", "FullName", "FamilyName",
38  "Weight", "FontBBox", "BlueValues", "OtherBlues",
39  "FamilyBlues", "FamilyOtherBlues", "StdHW", "StdVW",
40  "UNKNOWN_12", "UniqueID", "XUID", "charset",
41  "Encoding", "CharStrings", "Private", "Subrs",
42  "defaultWidthX", "nominalWidthX", "UNKNOWN_22", "UNKNOWN_23",
43  "UNKNOWN_24", "UNKNOWN_25", "UNKNOWN_26", "UNKNOWN_27",
44  "UNKNOWN_28", "UNKNOWN_29", "UNKNOWN_30", "UNKNOWN_31",
45  "Copyright", "isFixedPitch", "ItalicAngle", "UnderlinePosition",
46  "UnderlineThickness", "PaintType", "CharstringType", "FontMatrix",
47  "StrokeWidth", "BlueScale", "BlueShift", "BlueFuzz",
48  "StemSnapH", "StemSnapV", "ForceBold", "UNKNOWN_12_15",
49  "UNKNOWN_12_16", "LanguageGroup", "ExpansionFactor", "initialRandomSeed",
50  "SyntheticBase", "PostScript", "BaseFontName", "BaseFontBlend",
51  "UNKNOWN_12_24", "UNKNOWN_12_25", "UNKNOWN_12_26", "UNKNOWN_12_27",
52  "UNKNOWN_12_28", "UNKNOWN_12_29", "ROS", "CIDFontVersion",
53  "CIDFontRevision", "CIDFontType", "CIDCount", "UIDBase",
54  "FDArray", "FDSelect", "FontName"
55 };
56 
57 const int Cff::operator_types[] = {
58  tSID, tSID, tSID, tSID, // version, Notice, FullName, FamilyName
59  tSID, tArray4, tP+tArray, tP+tArray, // Weight, FontBBox, BlueValues, OtherBlues
60  tP+tArray, tP+tArray, tP+tNumber, tP+tNumber, // FamBlues, FamOthBlues, StdHW, StdVW
61  tNone, tNumber, tArray, tOffset, // escape, UniqueID, XUID, charset
62  tOffset, tOffset, tPrivateType, tP+tLocalOffset, // Encoding, CharStrings, Private, Subrs
63  tP+tNumber, tP+tNumber, tNone, tNone, // defaultWX, nominalWX, 22, 23
64  tNone, tNone, tNone, tNone, // 24, 25, 26, 27
65  tNone, tNone, tNone, tNone, // 28, 29, 30, 31
66  tSID, tBoolean, tNumber, tNumber, // Copyright, isFixedPitch, ItalicAngle, UnderlinePosition
67  tNumber, tNumber, tNumber, tArray6, // UnderlineThickness, PaintType, CharstringType, FontMatrix
68  tNumber, tP+tNumber, tP+tNumber, tP+tNumber, // StrokeWidth, BlueScale, BlueShift, BlueFuzz
69  tP+tArray, tP+tArray, tP+tBoolean, tNone, // StemSnapH, StemSnapV, ForceBold, 12 15
70  tNone, tP+tNumber, tP+tNumber, tP+tNumber, // 12 16, LanguageGroup, ExpansionFactor, initialRandomSeed
71  tNumber, tSID, tSID, tArray, // SyntheticBase, PostScript, BaseFontName, BaseFontBlend
72  tNone, tNone, tNone, tNone, // 12 24, 12 25, 12 26, 12 27
73  tNone, tNone, tArray, tNumber, // 12 28, 12 29, ROS, CIDFontVersion
74  tNumber, tNumber, tNumber, tNumber, // CIDFontRevision, CIDFontType, CIDCount, UIDBase
75  tOffset, tOffset, tSID // FDArray, FDSelect, FontName
76 };
77 
79 static const char * const standard_strings[] = {
80  // Automatically generated from Appendix A of the CFF specification; do
81  // not edit. Size should be 391.
82  ".notdef", "space", "exclam", "quotedbl", "numbersign", "dollar",
83  "percent", "ampersand", "quoteright", "parenleft", "parenright",
84  "asterisk", "plus", "comma", "hyphen", "period", "slash", "zero", "one",
85  "two", "three", "four", "five", "six", "seven", "eight", "nine", "colon",
86  "semicolon", "less", "equal", "greater", "question", "at", "A", "B", "C",
87  "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R",
88  "S", "T", "U", "V", "W", "X", "Y", "Z", "bracketleft", "backslash",
89  "bracketright", "asciicircum", "underscore", "quoteleft", "a", "b", "c",
90  "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r",
91  "s", "t", "u", "v", "w", "x", "y", "z", "braceleft", "bar", "braceright",
92  "asciitilde", "exclamdown", "cent", "sterling", "fraction", "yen",
93  "florin", "section", "currency", "quotesingle", "quotedblleft",
94  "guillemotleft", "guilsinglleft", "guilsinglright", "fi", "fl", "endash",
95  "dagger", "daggerdbl", "periodcentered", "paragraph", "bullet",
96  "quotesinglbase", "quotedblbase", "quotedblright", "guillemotright",
97  "ellipsis", "perthousand", "questiondown", "grave", "acute", "circumflex",
98  "tilde", "macron", "breve", "dotaccent", "dieresis", "ring", "cedilla",
99  "hungarumlaut", "ogonek", "caron", "emdash", "AE", "ordfeminine", "Lslash",
100  "Oslash", "OE", "ordmasculine", "ae", "dotlessi", "lslash", "oslash", "oe",
101  "germandbls", "onesuperior", "logicalnot", "mu", "trademark", "Eth",
102  "onehalf", "plusminus", "Thorn", "onequarter", "divide", "brokenbar",
103  "degree", "thorn", "threequarters", "twosuperior", "registered", "minus",
104  "eth", "multiply", "threesuperior", "copyright", "Aacute", "Acircumflex",
105  "Adieresis", "Agrave", "Aring", "Atilde", "Ccedilla", "Eacute",
106  "Ecircumflex", "Edieresis", "Egrave", "Iacute", "Icircumflex", "Idieresis",
107  "Igrave", "Ntilde", "Oacute", "Ocircumflex", "Odieresis", "Ograve",
108  "Otilde", "Scaron", "Uacute", "Ucircumflex", "Udieresis", "Ugrave",
109  "Yacute", "Ydieresis", "Zcaron", "aacute", "acircumflex", "adieresis",
110  "agrave", "aring", "atilde", "ccedilla", "eacute", "ecircumflex",
111  "edieresis", "egrave", "iacute", "icircumflex", "idieresis", "igrave",
112  "ntilde", "oacute", "ocircumflex", "odieresis", "ograve", "otilde",
113  "scaron", "uacute", "ucircumflex", "udieresis", "ugrave", "yacute",
114  "ydieresis", "zcaron", "exclamsmall", "Hungarumlautsmall",
115  "dollaroldstyle", "dollarsuperior", "ampersandsmall", "Acutesmall",
116  "parenleftsuperior", "parenrightsuperior", "twodotenleader",
117  "onedotenleader", "zerooldstyle", "oneoldstyle", "twooldstyle",
118  "threeoldstyle", "fouroldstyle", "fiveoldstyle", "sixoldstyle",
119  "sevenoldstyle", "eightoldstyle", "nineoldstyle", "commasuperior",
120  "threequartersemdash", "periodsuperior", "questionsmall", "asuperior",
121  "bsuperior", "centsuperior", "dsuperior", "esuperior", "isuperior",
122  "lsuperior", "msuperior", "nsuperior", "osuperior", "rsuperior",
123  "ssuperior", "tsuperior", "ff", "ffi", "ffl", "parenleftinferior",
124  "parenrightinferior", "Circumflexsmall", "hyphensuperior", "Gravesmall",
125  "Asmall", "Bsmall", "Csmall", "Dsmall", "Esmall", "Fsmall", "Gsmall",
126  "Hsmall", "Ismall", "Jsmall", "Ksmall", "Lsmall", "Msmall", "Nsmall",
127  "Osmall", "Psmall", "Qsmall", "Rsmall", "Ssmall", "Tsmall", "Usmall",
128  "Vsmall", "Wsmall", "Xsmall", "Ysmall", "Zsmall", "colonmonetary",
129  "onefitted", "rupiah", "Tildesmall", "exclamdownsmall", "centoldstyle",
130  "Lslashsmall", "Scaronsmall", "Zcaronsmall", "Dieresissmall", "Brevesmall",
131  "Caronsmall", "Dotaccentsmall", "Macronsmall", "figuredash",
132  "hypheninferior", "Ogoneksmall", "Ringsmall", "Cedillasmall",
133  "questiondownsmall", "oneeighth", "threeeighths", "fiveeighths",
134  "seveneighths", "onethird", "twothirds", "zerosuperior", "foursuperior",
135  "fivesuperior", "sixsuperior", "sevensuperior", "eightsuperior",
136  "ninesuperior", "zeroinferior", "oneinferior", "twoinferior",
137  "threeinferior", "fourinferior", "fiveinferior", "sixinferior",
138  "seveninferior", "eightinferior", "nineinferior", "centinferior",
139  "dollarinferior", "periodinferior", "commainferior", "Agravesmall",
140  "Aacutesmall", "Acircumflexsmall", "Atildesmall", "Adieresissmall",
141  "Aringsmall", "AEsmall", "Ccedillasmall", "Egravesmall", "Eacutesmall",
142  "Ecircumflexsmall", "Edieresissmall", "Igravesmall", "Iacutesmall",
143  "Icircumflexsmall", "Idieresissmall", "Ethsmall", "Ntildesmall",
144  "Ogravesmall", "Oacutesmall", "Ocircumflexsmall", "Otildesmall",
145  "Odieresissmall", "OEsmall", "Oslashsmall", "Ugravesmall", "Uacutesmall",
146  "Ucircumflexsmall", "Udieresissmall", "Yacutesmall", "Thornsmall",
147  "Ydieresissmall", "001.000", "001.001", "001.002", "001.003", "Black",
148  "Bold", "Book", "Light", "Medium", "Regular", "Roman", "Semibold"
149 };
152 
153 static const int standard_encoding[] = {
154  // Automatically generated from Appendix B of the CFF specification; do
155  // not edit. Size should be 256.
156  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
157  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
158  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
159  0, 0, 1, 2, 3, 4, 5, 6, 7, 8,
160  9, 10, 11, 12, 13, 14, 15, 16, 17, 18,
161  19, 20, 21, 22, 23, 24, 25, 26, 27, 28,
162  29, 30, 31, 32, 33, 34, 35, 36, 37, 38,
163  39, 40, 41, 42, 43, 44, 45, 46, 47, 48,
164  49, 50, 51, 52, 53, 54, 55, 56, 57, 58,
165  59, 60, 61, 62, 63, 64, 65, 66, 67, 68,
166  69, 70, 71, 72, 73, 74, 75, 76, 77, 78,
167  79, 80, 81, 82, 83, 84, 85, 86, 87, 88,
168  89, 90, 91, 92, 93, 94, 95, 0, 0, 0,
169  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
170  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
171  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
172  0, 96, 97, 98, 99, 100, 101, 102, 103, 104,
173  105, 106, 107, 108, 109, 110, 0, 111, 112, 113,
174  114, 0, 115, 116, 117, 118, 119, 120, 121, 122,
175  0, 123, 0, 124, 125, 126, 127, 128, 129, 130,
176  131, 0, 132, 133, 0, 134, 135, 136, 137, 0,
177  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
178  0, 0, 0, 0, 0, 138, 0, 139, 0, 0,
179  0, 0, 140, 141, 142, 143, 0, 0, 0, 0,
180  0, 144, 0, 0, 0, 145, 0, 0, 146, 147,
181  148, 149, 0, 0, 0, 0
182 };
183 
184 static const int expert_encoding[] = {
185  // Automatically generated from Appendix B of the CFF specification; do
186  // not edit. Size should be 256.
187  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
188  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
189  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
190  0, 0, 1, 229, 230, 0, 231, 232, 233, 234,
191  235, 236, 237, 238, 13, 14, 15, 99, 239, 240,
192  241, 242, 243, 244, 245, 246, 247, 248, 27, 28,
193  249, 250, 251, 252, 0, 253, 254, 255, 256, 257,
194  0, 0, 0, 258, 0, 0, 259, 260, 261, 262,
195  0, 0, 263, 264, 265, 0, 266, 109, 110, 267,
196  268, 269, 0, 270, 271, 272, 273, 274, 275, 276,
197  277, 278, 279, 280, 281, 282, 283, 284, 285, 286,
198  287, 288, 289, 290, 291, 292, 293, 294, 295, 296,
199  297, 298, 299, 300, 301, 302, 303, 0, 0, 0,
200  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
201  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
202  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
203  0, 304, 305, 306, 0, 0, 307, 308, 309, 310,
204  311, 0, 312, 0, 0, 313, 0, 0, 314, 315,
205  0, 0, 316, 317, 318, 0, 0, 0, 158, 155,
206  163, 319, 320, 321, 322, 323, 324, 325, 0, 0,
207  326, 150, 164, 169, 327, 328, 329, 330, 331, 332,
208  333, 334, 335, 336, 337, 338, 339, 340, 341, 342,
209  343, 344, 345, 346, 347, 348, 349, 350, 351, 352,
210  353, 354, 355, 356, 357, 358, 359, 360, 361, 362,
211  363, 364, 365, 366, 367, 368, 369, 370, 371, 372,
212  373, 374, 375, 376, 377, 378
213 };
214 
215 static const int iso_adobe_charset[] = {
216  // Automatically generated from Appendix C of the CFF specification; do
217  // not edit.
218  0, 1, 2, 3, 4, 5, 6, 7, 8, 9,
219  10, 11, 12, 13, 14, 15, 16, 17, 18, 19,
220  20, 21, 22, 23, 24, 25, 26, 27, 28, 29,
221  30, 31, 32, 33, 34, 35, 36, 37, 38, 39,
222  40, 41, 42, 43, 44, 45, 46, 47, 48, 49,
223  50, 51, 52, 53, 54, 55, 56, 57, 58, 59,
224  60, 61, 62, 63, 64, 65, 66, 67, 68, 69,
225  70, 71, 72, 73, 74, 75, 76, 77, 78, 79,
226  80, 81, 82, 83, 84, 85, 86, 87, 88, 89,
227  90, 91, 92, 93, 94, 95, 96, 97, 98, 99,
228  100, 101, 102, 103, 104, 105, 106, 107, 108, 109,
229  110, 111, 112, 113, 114, 115, 116, 117, 118, 119,
230  120, 121, 122, 123, 124, 125, 126, 127, 128, 129,
231  130, 131, 132, 133, 134, 135, 136, 137, 138, 139,
232  140, 141, 142, 143, 144, 145, 146, 147, 148, 149,
233  150, 151, 152, 153, 154, 155, 156, 157, 158, 159,
234  160, 161, 162, 163, 164, 165, 166, 167, 168, 169,
235  170, 171, 172, 173, 174, 175, 176, 177, 178, 179,
236  180, 181, 182, 183, 184, 185, 186, 187, 188, 189,
237  190, 191, 192, 193, 194, 195, 196, 197, 198, 199,
238  200, 201, 202, 203, 204, 205, 206, 207, 208, 209,
239  210, 211, 212, 213, 214, 215, 216, 217, 218, 219,
240  220, 221, 222, 223, 224, 225, 226, 227, 228
241 };
242 
243 static const int expert_charset[] = {
244  // Automatically generated from Appendix C of the CFF specification; do
245  // not edit.
246  0, 1, 229, 230, 231, 232, 233, 234, 235, 236,
247  237, 238, 13, 14, 15, 99, 239, 240, 241, 242,
248  243, 244, 245, 246, 247, 248, 27, 28, 249, 250,
249  251, 252, 253, 254, 255, 256, 257, 258, 259, 260,
250  261, 262, 263, 264, 265, 266, 109, 110, 267, 268,
251  269, 270, 271, 272, 273, 274, 275, 276, 277, 278,
252  279, 280, 281, 282, 283, 284, 285, 286, 287, 288,
253  289, 290, 291, 292, 293, 294, 295, 296, 297, 298,
254  299, 300, 301, 302, 303, 304, 305, 306, 307, 308,
255  309, 310, 311, 312, 313, 314, 315, 316, 317, 318,
256  158, 155, 163, 319, 320, 321, 322, 323, 324, 325,
257  326, 150, 164, 169, 327, 328, 329, 330, 331, 332,
258  333, 334, 335, 336, 337, 338, 339, 340, 341, 342,
259  343, 344, 345, 346, 347, 348, 349, 350, 351, 352,
260  353, 354, 355, 356, 357, 358, 359, 360, 361, 362,
261  363, 364, 365, 366, 367, 368, 369, 370, 371, 372,
262  373, 374, 375, 376, 377, 378
263 };
264 
265 static const int expert_subset_charset[] = {
266  // Automatically generated from Appendix C of the CFF specification; do
267  // not edit.
268  0, 1, 231, 232, 235, 236, 237, 238, 13, 14,
269  15, 99, 239, 240, 241, 242, 243, 244, 245, 246,
270  247, 248, 27, 28, 249, 250, 251, 253, 254, 255,
271  256, 257, 258, 259, 260, 261, 262, 263, 264, 265,
272  266, 109, 110, 267, 268, 269, 270, 272, 300, 301,
273  302, 305, 314, 315, 158, 155, 163, 320, 321, 322,
274  323, 324, 325, 326, 150, 164, 169, 327, 328, 329,
275  330, 331, 332, 333, 334, 335, 336, 337, 338, 339,
276  340, 341, 342, 343, 344, 345, 346
277 };
278 
279 static const uint8_t default_dict_cff_data[] = {
280  // CFF header
281  1, 0, // format major and minor version
282  4, // header size
283  4, // absolute offset size
284 
285  // Name INDEX
286  0, 1, // one element in index
287  1, // offset size
288  1, 14, // offset array
289  '%', 'D', 'E', 'F', 'A', 'U', 'L', 'T', 'D', 'I', 'C', 'T', '%',
290 
291  // Top DICT INDEX
292  0, 1, // one element in index
293  1, // offset size
294  1, 92, // offset array
295  // and the DICT
296  139, 12, 1, // isFixedPitch false
297  139, 12, 2, // ItalicAngle 0
298  39, 12, 3, // UnderlinePosition -100
299  189, 12, 4, // UnderlineThickness 50
300  139, 12, 5, // PaintType 0
301  141, 12, 6, // CharstringType 2
302  30, 0x0A, 0x00, 0x1F, 139, 139, 30, 0x0A, 0x00, 0x1F, 139, 139, 12, 7,
303  // FontMatrix 0.001 0 0 0.001 0 0
304  139, 139, 139, 139, 5, // FontBBox 0 0 0 0
305  139, 12, 8, // StrokeWidth 0
306  139, 15, // charset 0
307  139, 16, // Encoding 0
308  139, 12, 31, // CIDFontVersion 0
309  139, 12, 32, // CIDFontRevision 0
310  139, 12, 33, // CIDFontType 0
311  28, 34, 16, 12, 34, // CIDCount 8720
312  30, 0x0A, 0x03, 0x96, 0x25, 0xFF, 12, 9, // BlueScale 0.039625
313  146, 12, 10, // BlueShift 7
314  140, 12, 11, // BlueFuzz 1
315  139, 12, 14, // ForceBold false
316  139, 12, 17, // LanguageGroup 0
317  30, 0x0A, 0x06, 0xFF, 12, 18, // ExpansionFactor 0.06
318  139, 12, 19, // initialRandomSeed 0
319  139, 20, // defaultWidthX 0
320  139, 21, // nominalWidthX 0
321 
322  // String INDEX
323  0, 0,
324 
325  // Gsubr INDEX
326  0, 0
327 };
328 
329 static const Cff::Dict&
331 {
333  return static_cast<Cff::Font*>(cff.font())->top_dict();
334 }
335 
336 
337 #define POS_GT(pos1, pos2) ((unsigned)(pos1) > (unsigned)(pos2))
338 
339 
340 Cff::Cff(const String& s, unsigned units_per_em, ErrorHandler* errh)
341  : _data_string(s), _data(reinterpret_cast<const uint8_t *>(_data_string.data())), _len(_data_string.length()),
342  _strings_map(-2), _units_per_em(units_per_em)
343 {
345  "NSTANDARD_STRINGS defined incorrectly");
346  static_assert((sizeof(standard_encoding) / sizeof(standard_encoding[0])) == 256,
347  "standard_encoding has wrong size");
348  static_assert((sizeof(expert_encoding) / sizeof(expert_encoding[0])) == 256,
349  "expert_encoding has wrong size");
351 }
352 
354 {
355  for (int i = 0; i < _gsubrs_cs.size(); i++)
356  delete _gsubrs_cs[i];
357  for (int i = 0; i < _fonts.size(); ++i)
358  delete _fonts[i];
359 }
360 
361 /*
362  * Parsing the file header
363  */
364 
365 int
367 {
368  if (_gsubrs_index.error() >= 0) // already done
369  return 0;
370 
371  // parse header
372  if (_len == 0)
373  return errh->error("not a PostScript-flavored OpenType font"), -EFAULT;
374  if (_len < HEADER_SIZE)
375  return errh->error("CFF file corrupted (too small)"), -EFAULT;
376  if (_data[0] != 1) // major version number
377  return errh->error("bad major version number %d", _data[0]), -ERANGE;
378  int hdrSize = _data[2], offSize = _data[3];
379  if (hdrSize < 4 || hdrSize > _len || offSize < 1 || offSize > 4)
380  return errh->error("corrupted file header"), -EINVAL;
381  int name_index_pos = hdrSize;
382 
383  // parse name INDEX
384  IndexIterator niter(_data, name_index_pos, _len, errh, "Name INDEX");
385  if (niter.error() < 0)
386  return niter.error();
387  _name_index.clear();
388  for (; niter; niter++) {
389  const uint8_t *d0 = niter[0];
390  const uint8_t *d1 = niter[1];
391  if (d0 == d1 || d0[0] == 0)
392  _name_index.push_back(PermString());
393  else
394  _name_index.push_back(PermString(reinterpret_cast<const char *>(d0), d1 - d0));
395  }
396  int top_dict_index_pos = niter.index_end() - _data;
397 
398  // check top DICT INDEX
399  _top_dict_index = IndexIterator(_data, top_dict_index_pos, _len, errh, "Top DICT INDEX");
400  if (_top_dict_index.error() < 0)
401  return _top_dict_index.error();
402  else if (_top_dict_index.nitems() != nfonts())
403  return errh->error("invalid font: Top DICT INDEX has %d elements, but there are %d fonts", _top_dict_index.nitems(), nfonts()), -EINVAL;
404  int string_index_pos = _top_dict_index.index_end() - _data;
405 
406  // check strings INDEX
407  _strings_index = IndexIterator(_data, string_index_pos, _len, errh, "Strings INDEX");
408  if (_strings_index.error() < 0)
409  return _strings_index.error();
410  else if (NSTANDARD_STRINGS + _strings_index.nitems() - 1 > MAX_SID)
411  return errh->error("too many strings defined in font"), -EINVAL;
413  int global_subr_index_pos = _strings_index.index_end() - _data;
414 
415  // check gsubr INDEX
416  _gsubrs_index = IndexIterator(_data, global_subr_index_pos, _len, errh, "Gsubrs INDEX");
417  if (_gsubrs_index.error() < 0)
418  return _gsubrs_index.error();
419  _gsubrs_cs.assign(ngsubrs(), 0);
420 
421  return 0;
422 }
423 
424 int
426 {
427  if (!s) // XXX?
428  return -1;
429 
430  // check standard strings
431  if (standard_permstrings_map["a"] < 0)
432  for (int i = 0; i < NSTANDARD_STRINGS; i++) {
433  if (!standard_permstrings[i])
436  }
438  if (sid >= 0)
439  return sid;
440 
441  // check user strings
442  sid = _strings_map[s];
443  if (sid >= -1)
444  return sid;
445 
446  for (int i = 0; i < _strings.size(); i++)
447  if (!_strings[i] && s.length() == _strings_index[i+1] - _strings_index[i] && memcmp(s.c_str(), _strings_index[i], s.length()) == 0) {
448  _strings[i] = s;
449  _strings_map.insert(s, i + NSTANDARD_STRINGS);
450  return i + NSTANDARD_STRINGS;
451  }
452 
453  _strings_map.insert(s, -1);
454  return -1;
455 }
456 
457 String
459 {
460  if (sid < 0)
461  return String();
462  else if (sid < NSTANDARD_STRINGS)
463  return String(sid_permstring(sid));
464  else {
466  if (sid >= _strings.size())
467  return String();
468  else if (_strings[sid])
469  return String(_strings[sid]);
470  else
471  return String(reinterpret_cast<const char *>(_strings_index[sid]), _strings_index[sid + 1] - _strings_index[sid]);
472  }
473 }
474 
477 {
478  if (sid < 0)
479  return PermString();
480  else if (sid < NSTANDARD_STRINGS) {
483  return standard_permstrings[sid];
484  } else {
486  if (sid >= _strings.size())
487  return PermString();
488  else if (_strings[sid])
489  return _strings[sid];
490  else {
491  PermString s = PermString(reinterpret_cast<const char *>(_strings_index[sid]), _strings_index[sid + 1] - _strings_index[sid]);
492  _strings[sid] = s;
493  _strings_map.insert(s, sid + NSTANDARD_STRINGS);
494  return s;
495  }
496  }
497 }
498 
501 {
502  if (!errh)
504 
505  if (!ok())
506  return errh->error("invalid CFF"), (FontParent *) 0;
507 
508  // search for a font named 'font_name'
509  int findex;
510  for (findex = 0; findex < _name_index.size(); ++findex) {
511  if (_name_index[findex]
512  && (!font_name || font_name == _name_index[findex]))
513  break;
514  }
515  if (findex >= _name_index.size()) {
516  if (!font_name)
517  errh->error("no fonts in CFF");
518  else
519  errh->error("font %<%s%> not found", font_name.c_str());
520  return 0;
521  }
522 
523  // return font
524  for (int i = 0; i < _fonts.size(); ++i)
525  if (_fonts[i]->_font_index == findex)
526  return _fonts[i];
527 
528  int td_offset = _top_dict_index[findex] - _data;
529  int td_length = _top_dict_index[findex + 1] - _top_dict_index[findex];
530  Dict top_dict(this, td_offset, td_length, errh, "Top DICT");
531  if (!top_dict.ok())
532  return 0;
533 
535  if (top_dict.has_first(oROS))
536  fp = new Cff::CIDFont(this, _name_index[findex], top_dict, errh);
537  else
538  fp = new Cff::Font(this, _name_index[findex], top_dict, errh);
539  fp->_font_index = findex;
540  _fonts.push_back(fp);
541  return fp;
542 }
543 
544 static inline int
545 subr_bias(int charstring_type, int nsubrs)
546 {
547  if (charstring_type == 1)
548  return 0;
549  else if (nsubrs < 1240)
550  return 107;
551  else if (nsubrs < 33900)
552  return 1131;
553  else
554  return 32768;
555 }
556 
557 Charstring *
559 {
560  i += subr_bias(2, ngsubrs());
561  if (i < 0 || i >= ngsubrs())
562  return 0;
563  if (!_gsubrs_cs[i]) {
564  const uint8_t *s1 = _gsubrs_index[i];
565  int slen = _gsubrs_index[i + 1] - s1;
567  if (slen == 0)
568  return 0;
569  else
570  _gsubrs_cs[i] = new Type2Charstring(cs);
571  }
572  return _gsubrs_cs[i];
573 }
574 
575 
576 /*****
577  * Cff::Charset
578  **/
579 
580 Cff::Charset::Charset(const Cff *cff, int pos, int nglyphs, int max_sid, ErrorHandler *errh)
581 {
583 }
584 
585 void
587 {
588  if (!errh)
590 
591  _sids.reserve(nglyphs);
592 
593  if (pos == 0)
594  assign(iso_adobe_charset, sizeof(iso_adobe_charset) / sizeof(int), nglyphs);
595  else if (pos == 1)
596  assign(expert_charset, sizeof(expert_charset) / sizeof(int), nglyphs);
597  else if (pos == 2)
598  assign(expert_subset_charset, sizeof(expert_subset_charset) / sizeof(int), nglyphs);
599  else
601 
602  if (_error >= 0)
603  for (int g = 0; g < _sids.size(); g++) {
604  if (_gids[_sids[g]] >= 0) {
605  errh->error("glyph %<%s%> in charset twice", cff->sid_permstring(_sids[g]).c_str());
606  _error = -EEXIST;
607  }
608  _gids[_sids[g]] = g;
609  }
610 }
611 
612 void
613 Cff::Charset::assign(const int *data, int size, int nglyphs)
614 {
615  if (size < nglyphs)
616  size = nglyphs;
617  _sids.resize(size);
618  memcpy(&_sids[0], data, sizeof(const int) * size);
619  _gids.resize(data[size-1] + 1, -1);
620  _error = 0;
621 }
622 
623 int
625 {
626  const uint8_t *data = cff->data();
627  int len = cff->length();
628 
629  if (pos + 1 > len)
630  return errh->error("charset position out of range"), -EFAULT;
631 
632  _sids.push_back(0);
633  int actual_max_sid = 0;
634 
635  int format = data[pos];
636  if (format == 0) {
637  if (pos + 1 + (nglyphs - 1) * 2 > len)
638  return errh->error("charset [format 0] out of range"), -EFAULT;
639  const uint8_t *p = data + pos + 1;
640  for (; _sids.size() < nglyphs; p += 2) {
641  int sid = (p[0] << 8) | p[1];
642  if (sid > actual_max_sid)
643  actual_max_sid = sid;
644  _sids.push_back(sid);
645  }
646 
647  } else if (format == 1) {
648  const uint8_t *p = data + pos + 1;
649  for (; _sids.size() < nglyphs; p += 3) {
650  if (p + 3 > data + len)
651  return errh->error("charset [format 1] out of range"), -EFAULT;
652  int sid = (p[0] << 8) | p[1];
653  int n = p[2];
654  if (sid + n > actual_max_sid)
655  actual_max_sid = sid + n;
656  for (int i = 0; i <= n; i++)
657  _sids.push_back(sid + i);
658  }
659 
660  } else if (format == 2) {
661  const uint8_t *p = data + pos + 1;
662  for (; _sids.size() < nglyphs; p += 4) {
663  if (p + 4 > data + len)
664  return errh->error("charset [format 2] out of range"), -EFAULT;
665  int sid = (p[0] << 8) | p[1];
666  int n = (p[2] << 8) | p[3];
667  if (sid + n > actual_max_sid)
668  actual_max_sid = sid + n;
669  for (int i = 0; i <= n; i++)
670  _sids.push_back(sid + i);
671  }
672 
673  } else
674  return errh->error("unknown charset format %d", format), -EINVAL;
675 
676  if (max_sid >= 0 && actual_max_sid > max_sid)
677  return errh->error("charset [format %d] uses bad SID %d", format, actual_max_sid), -EINVAL;
678  _sids.resize(nglyphs);
679  _gids.resize(actual_max_sid + 1, -1);
680  return 0;
681 }
682 
683 
684 /*****
685  * Cff::FDSelect
686  **/
687 
688 void
690 {
691  if (!errh)
693  if (_my_fds)
694  delete[] _fds;
695  _fds = 0;
696  _my_fds = false;
697  _nglyphs = nglyphs;
698  _error = parse(cff, pos, nglyphs, errh);
699 }
700 
702 {
703  if (_my_fds)
704  delete[] _fds;
705 }
706 
707 int
709 {
710  const uint8_t *data = cff->data();
711  int len = cff->length();
712 
713  if (pos + 1 > len)
714  return errh->error("FDSelect position out of range"), -EFAULT;
715 
716  int format = data[pos];
717  if (format == 0) {
718  if (pos + 1 + nglyphs > len)
719  return errh->error("FDSelect [format 0] out of range"), -EFAULT;
720  _fds = data + pos + 1;
721  _my_fds = false;
722  return 0;
723 
724  } else if (format == 3) {
725  int nranges = (data[pos+1] << 8) | data[pos+2];
726  if (pos + 3 + 3*nranges + 2 > len)
727  return errh->error("FDSelect [format 3] out of range"), -EFAULT;
728 
729  const uint8_t *p = data + pos + 3;
730  int last_glyph = (p[3*nranges] << 8) | p[3*nranges + 1];
731  if (p[0] || p[1] || last_glyph != nglyphs)
732  return errh->error("FDSelect [format 3] bad values"), -EINVAL;
733 
734  _fds = new uint8_t[nglyphs];
735  _my_fds = true;
736  int curglyph = 0;
737  for (; curglyph < nglyphs; p += 3) {
738  int nextglyph = (p[3] << 8) | p[4];
739  if (nextglyph > nglyphs || nextglyph < curglyph)
740  return errh->error("FDSelect [format 3] sorting error"), -EINVAL;
741  memset(const_cast<uint8_t *>(_fds + curglyph), p[2], nextglyph - curglyph);
742  curglyph = nextglyph;
743  }
744  return 0;
745 
746  } else
747  return errh->error("unknown charset format %d", format), -EINVAL;
748 }
749 
750 
751 /*****
752  * Cff::IndexIterator
753  **/
754 
755 Cff::IndexIterator::IndexIterator(const uint8_t *data, int pos, int len, ErrorHandler *errh, const char *index_name)
756  : _contents(0), _offset(0), _last_offset(0)
757 {
758  if (!errh)
760 
761  // check header
762  int nitems = 0;
763  if (POS_GT(pos + 2, len)) {
764  errh->error("%s: position out of range", index_name);
765  _offsize = -EFAULT;
766  } else if (data[pos] == 0 && data[pos + 1] == 0) {
767  _contents = data + pos + 2;
768  _offsize = 0;
769  } else if (POS_GT(pos + 3, len)) {
770  errh->error("%s: position out of range", index_name);
771  _offsize = -EFAULT;
772  } else if ((_offsize = data[pos + 2]), (_offsize < 1 || _offsize > 4)) {
773  errh->error("%s: offset size %d out of range", index_name, _offsize);
774  _offsize = -EINVAL;
775  } else {
776  nitems = (data[pos] << 8) | data[pos + 1];
777  if (POS_GT(pos + 3 + (nitems + 1) * _offsize, len)) {
778  errh->error("%s: data out of range", index_name);
779  _offsize = -EFAULT;
780  } else {
781  _offset = data + pos + 3;
784  }
785  }
786 
787  // check items in offset array
788  uint32_t max_doff_allowed = len - (pos + 2 + (nitems + 1) * _offsize);
789  uint32_t last_doff = 1;
790  for (const uint8_t *o = _offset; o <= _last_offset && _offsize > 0; o += _offsize) {
791  uint32_t doff = offset_at(o);
792  if (doff > max_doff_allowed) {
793  errh->error("%s: element out of range", index_name);
794  _offsize = -EFAULT;
795  } else if (doff < last_doff) {
796  errh->error("%s: garbled elements", index_name);
797  break;
798  }
799  last_doff = doff;
800  }
801 }
802 
803 const uint8_t *
805 {
806  if (_offsize <= 0)
807  return _contents;
808  else
809  return _contents + offset_at(_last_offset);
810 }
811 
812 int
814 {
815  if (_offsize <= 0)
816  return 0;
817  else
818  return (_last_offset - _offset) / _offsize;
819 }
820 
821 
822 
823 /*****
824  * Cff::Dict
825  **/
826 
828  : _cff(0), _pos(0), _error(-ENOENT)
829 {
830 }
831 
832 Cff::Dict::Dict(Cff *cff, int pos, int dict_len, ErrorHandler *errh, const char *dict_name)
833 {
834  assign(cff, pos, dict_len, errh, dict_name);
835 }
836 
837 int
838 Cff::Dict::assign(Cff *cff, int pos, int dict_len, ErrorHandler *errh, const char *dict_name)
839 {
840  _cff = cff;
841  _pos = pos;
842  _operators.clear();
843  _pointers.clear();
844  _operands.clear();
845 
846  if (!errh)
848 
849  const uint8_t *data = cff->data() + pos;
850  const uint8_t *end_data = data + dict_len;
851 
852  _pointers.push_back(0);
853  while (data < end_data)
854  switch (data[0]) {
855 
856  case 0: case 1: case 2: case 3: case 4: case 5: case 6: case 7:
857  case 8: case 9: case 10: case 11: case 13: case 14: case 15:
858  case 16: case 17: case 18: case 19: case 20: case 21:
859  _operators.push_back(data[0]);
860  _pointers.push_back(_operands.size());
861  data++;
862  break;
863 
864  case 22: case 23: case 24: case 25: case 26: case 27: case 31:
865  case 255: // reserved
866  errh->error("%s: reserved operator %d", dict_name, data[0]);
867  return (_error = -ERANGE);
868 
869  case 12:
870  if (data + 1 >= end_data)
871  goto runoff;
872  _operators.push_back(32 + data[1]);
873  _pointers.push_back(_operands.size());
874  data += 2;
875  break;
876 
877  case 28: {
878  if (data + 2 >= end_data)
879  goto runoff;
880  int16_t val = (data[1] << 8) | data[2];
881  _operands.push_back(val);
882  data += 3;
883  break;
884  }
885 
886  case 29: {
887  if (data + 4 >= end_data)
888  goto runoff;
889  int32_t val = (data[1] << 24) | (data[2] << 16) | (data[3] << 8) | data[4];
890  _operands.push_back(val);
891  data += 5;
892  break;
893  }
894 
895  case 30: {
896  char buf[1024];
897  int pos = 0;
898  if (data + 1 >= end_data)
899  goto runoff;
900  for (data++; data < end_data && pos < 1020; data++) {
901  int d = *data;
902  for (int i = 0; i < 2; i++, d <<= 4) {
903  int digit = (d >> 4) & 0xF;
904  switch (digit) {
905  case 10:
906  buf[pos++] = '.';
907  break;
908  case 11:
909  buf[pos++] = 'E';
910  break;
911  case 12:
912  buf[pos++] = 'E';
913  buf[pos++] = '-';
914  break;
915  case 13:
916  errh->error("%s: bad digit in real number", dict_name);
917  goto invalid;
918  case 14:
919  buf[pos++] = '-';
920  break;
921  case 15:
922  goto found;
923  default:
924  buf[pos++] = digit + '0';
925  break;
926  }
927  }
928  }
929  // number not found
930  goto runoff;
931  found:
932  char *endptr;
933  buf[pos] = '\0';
934  _operands.push_back(strtod(buf, &endptr));
935  if (*endptr) {
936  errh->error("%s: real number syntax error", dict_name);
937  goto invalid;
938  }
939  data++;
940  break;
941  }
942 
943  case 247: case 248: case 249: case 250: {
944  if (data + 1 >= end_data)
945  goto runoff;
946  int val = ((data[0] - 247) << 8) + data[1] + 108;
947  _operands.push_back(val);
948  data += 2;
949  break;
950  }
951 
952  case 251: case 252: case 253: case 254: {
953  if (data + 1 >= end_data)
954  goto runoff;
955  int val = -((data[0] - 251) << 8) - data[1] - 108;
956  _operands.push_back(val);
957  data += 2;
958  break;
959  }
960 
961  default:
962  _operands.push_back(data[0] - 139);
963  data++;
964  break;
965 
966  }
967 
968  // not closed by an operator?
969  if (_pointers.back() != _operands.size()) {
970  errh->error("%s: not closed by an operator", dict_name);
971  goto invalid;
972  }
973 
974  return (_error = 0);
975 
976  runoff:
977  errh->error("%s: runoff end of DICT", dict_name);
978  return (_error = -EFAULT);
979 
980  invalid:
981  return (_error = -EINVAL);
982 }
983 
984 int
985 Cff::Dict::check(bool is_private, ErrorHandler *errh, const char *dict_name) const
986 {
987  if (!errh)
989  int before_nerrors = errh->nerrors();
990 
991  // keep track of operator reuse
992  Vector<int> operators_used;
993 
994  for (int i = 0; i < _operators.size(); i++) {
995  int arity = _pointers[i+1] - _pointers[i];
996  double num = (arity == 0 ? 0 : _operands[_pointers[i]]);
997  double truncnum = floor(num);
998  int op = _operators[i];
999  int type = (op > oLastOperator ? tNone : operator_types[op]);
1000 
1001  // check reuse
1002  if (op >= operators_used.size())
1003  operators_used.resize(op + 1, 0);
1004  if (operators_used[op] && (type & tTypeMask) != tNone)
1005  errh->error("%s: operator %<%s%> specified twice", dict_name, operator_names[op]);
1006  operators_used[op]++;
1007 
1008  // check data
1009  switch (type & tTypeMask) {
1010 
1011  case tNone:
1012  if (op >= 32)
1013  errh->warning("%s: unknown operator %<12 %d%>", dict_name, op - 32);
1014  else
1015  errh->warning("%s: unknown operator %<%d%>", dict_name, op);
1016  continue;
1017 
1018  case tSID:
1019  if (arity != 1 || num != truncnum || num < 0 || num > _cff->max_sid())
1020  goto bad_data;
1021  break;
1022 
1023  case tFontNumber:
1024  if (arity != 1 || num != truncnum || num < 0 || num >= _cff->nfonts())
1025  goto bad_data;
1026  break;
1027 
1028  case tBoolean:
1029  if (arity != 1)
1030  goto bad_data;
1031  else if (num != 0 && num != 1)
1032  errh->warning("%s: data for Boolean operator %<%s%> not 0 or 1", dict_name, operator_names[op]);
1033  break;
1034 
1035  case tNumber:
1036  if (arity != 1)
1037  goto bad_data;
1038  break;
1039 
1040  case tOffset:
1041  if (arity != 1 || num != truncnum || num < 0 || num >= _cff->length())
1042  goto bad_data;
1043  break;
1044 
1045  case tLocalOffset:
1046  if (arity != 1 || num != truncnum || _pos + num < 0 || _pos + num >= _cff->length())
1047  goto bad_data;
1048  break;
1049 
1050  case tPrivateType: {
1051  if (arity != 2 || num != truncnum || num < 0)
1052  goto bad_data;
1053  double off = _operands[_pointers[i] + 1];
1054  if (off < 0 || off + num > _cff->length())
1055  goto bad_data;
1056  break;
1057  }
1058 
1059  case tArray2: case tArray3: case tArray4:
1060  case tArray5: case tArray6:
1061  if (arity != (type & tTypeMask) - tArray2 + 2)
1062  goto bad_data;
1063  break;
1064 
1065  case tArray:
1066  break;
1067 
1068  }
1069 
1070  // check dict location
1071  if (((type & tPrivate) != 0) != is_private)
1072  errh->warning("%s: operator %<%s%> in wrong DICT", dict_name, operator_names[op]);
1073 
1074  continue;
1075 
1076  bad_data:
1077  errh->error("%s: bad data for operator %<%s%>", dict_name, operator_names[op]);
1078  }
1079 
1080  return (errh->nerrors() != before_nerrors ? -1 : 0);
1081 }
1082 
1083 bool
1085 {
1086  for (int i = 0; i < _operators.size(); i++)
1087  if (_operators[i] == op)
1088  return true;
1089  return false;
1090 }
1091 
1092 bool
1094 {
1095  out.clear();
1096  for (int i = 0; i < _operators.size(); i++)
1097  if (_operators[i] == op) {
1098  for (int j = _pointers[i]; j < _pointers[i+1]; j++)
1099  out.push_back(_operands[j]);
1100  return true;
1101  }
1102  return false;
1103 }
1104 
1105 bool
1107 {
1108  for (int i = 0; i < _operators.size(); i++)
1109  if (_operators[i] == op && _pointers[i] + 1 == _pointers[i+1]) {
1110  *val = (int) _operands[_pointers[i]];
1111  return true;
1112  }
1113  return false;
1114 }
1115 
1116 bool
1118 {
1119  for (int i = 0; i < _operators.size(); i++)
1120  if (_operators[i] == op && _pointers[i] + 1 == _pointers[i+1]) {
1121  *val = _operands[_pointers[i]];
1122  return true;
1123  }
1124  return false;
1125 }
1126 
1127 bool
1129 {
1130  return xvalue(op, out) || default_dict().xvalue(op, out);
1131 }
1132 
1133 bool
1135 {
1136  return xvalue(op, val) || default_dict().xvalue(op, val);
1137 }
1138 
1139 bool
1141 {
1142  return xvalue(op, val) || default_dict().xvalue(op, val);
1143 }
1144 
1145 void
1146 Cff::Dict::unparse(ErrorHandler *errh, const char *dict_name) const
1147 {
1148  StringAccum sa;
1149  for (int i = 0; i < _operators.size(); i++) {
1150  sa.clear();
1151  if (_pointers[i] + 1 == _pointers[i+1])
1152  sa << _operands[_pointers[i]];
1153  else {
1154  sa << "[";
1155  for (int j = _pointers[i]; j < _pointers[i+1]; j++)
1156  sa << _operands[j] << ' ';
1157  sa.pop_back();
1158  sa << "]";
1159  }
1160  errh->message("%s: %s %s", dict_name, operator_names[_operators[i]], sa.c_str());
1161  }
1162 }
1163 
1164 
1165 /*****
1166  * CffFontParent
1167  **/
1168 
1169 static int
1170 handle_private(Cff *cff, const Cff::Dict &top_dict, Cff::Dict &private_dict,
1171  double &default_width_x, double &nominal_width_x,
1172  Cff::IndexIterator &subrs_index, Vector<Charstring *> &subrs_cs,
1173  ErrorHandler *errh)
1174 {
1175  Vector<double> private_info;
1176  top_dict.value(Cff::oPrivate, private_info);
1177  int private_offset = (int) private_info[1];
1178  private_dict.assign(cff, private_offset, (int) private_info[0], errh, "Private DICT");
1179  if (private_dict.error() < 0)
1180  return private_dict.error();
1181  else if (private_dict.check(true, errh, "Private DICT") < 0)
1182  return -EINVAL;
1183  //private_dict.unparse(errh, "Private DICT");
1184 
1185  private_dict.value(Cff::oDefaultWidthX, &default_width_x);
1186  private_dict.value(Cff::oNominalWidthX, &nominal_width_x);
1187  if (private_dict.has(Cff::oSubrs)) {
1188  int subrs_offset = 0;
1189  private_dict.value(Cff::oSubrs, &subrs_offset);
1190  subrs_index = Cff::IndexIterator(cff->data(), private_offset + subrs_offset, cff->length(), errh, "Subrs INDEX");
1191  if (subrs_index.error() < 0)
1192  return subrs_index.error();
1193  }
1194  subrs_cs.assign(subrs_index.nitems(), 0);
1195  return 0;
1196 }
1197 
1198 
1200  : CharstringProgram(cff->units_per_em()), _cff(cff), _error(-1)
1201 {
1202 }
1203 
1204 Charstring *
1205 Cff::FontParent::charstring(const IndexIterator &iiter, int which) const
1206 {
1207  const uint8_t *s1 = iiter[which];
1208  int slen = iiter[which + 1] - s1;
1209  String cs = _cff->data_string().substring(s1 - _cff->data(), slen);
1210  if (slen == 0)
1211  return 0;
1212  else if (_charstring_type == 1)
1213  return new Type1Charstring(cs);
1214  else
1215  return new Type2Charstring(cs);
1216 }
1217 
1218 Charstring *
1220 {
1221  return _cff->gsubr(i);
1222 }
1223 
1224 int
1226 {
1227  return Efont::subr_bias(2, ngsubrs_x());
1228 }
1229 
1230 
1231 /*****
1232  * CffFont
1233  **/
1234 
1236  : ChildFont(cff, 0, 2, top_dict, errh), _font_name(font_name),
1237  _t1encoding(0)
1238 {
1240  if (_error < 0)
1241  return;
1242 
1243  // extract CharStrings
1244  // must use xvalue because we could be creating the default dict!
1245  int charstrings_offset = 0;
1246  _top_dict.xvalue(oCharStrings, &charstrings_offset);
1247  _charstrings_index = Cff::IndexIterator(cff->data(), charstrings_offset, cff->length(), errh, "CharStrings INDEX");
1248  if (_charstrings_index.error() < 0) {
1250  return;
1251  }
1253 
1254  int charset = 0;
1257  if (_charset.error() < 0) {
1258  _error = _charset.error();
1259  return;
1260  }
1261 
1262  int Encoding = 0;
1264  if (parse_encoding(Encoding, errh) < 0)
1265  return;
1266 
1267  // success!
1268  _error = 0;
1269 }
1270 
1272 {
1273  for (int i = 0; i < _charstrings_cs.size(); i++)
1274  delete _charstrings_cs[i];
1275  delete _t1encoding;
1276 }
1277 
1278 int
1280 {
1281  _encoding_pos = pos;
1282  for (int i = 0; i < 256; i++)
1283  _encoding[i] = 0;
1284 
1285  // check for standard encodings
1286  if (pos == 0)
1287  return assign_standard_encoding(standard_encoding);
1288  else if (pos == 1)
1289  return assign_standard_encoding(expert_encoding);
1290 
1291  // otherwise, a custom encoding
1292  const uint8_t *data = _cff->data();
1293  int len = _cff->length();
1294  if (pos + 1 > len)
1295  return errh->error("Encoding position out of range"), -EFAULT;
1296  bool supplemented = (data[pos] & 0x80) != 0;
1297  int format = (data[pos] & 0x7F);
1298 
1299  int retval = 0;
1300  int endpos, g = 1;
1301  if (format == 0) {
1302  endpos = pos + 2 + data[pos + 1];
1303  if (endpos > len)
1304  return errh->error("Encoding[0] out of range"), -EFAULT;
1305  const uint8_t *p = data + pos + 2;
1306  int n = data[pos + 1];
1307  for (; g <= n; g++, p++) {
1308  int e = p[0];
1309  if (_encoding[e])
1310  retval = 1;
1311  _encoding[e] = g;
1312  }
1313 
1314  } else if (format == 1) {
1315  endpos = pos + 2 + data[pos + 1] * 2;
1316  if (endpos > len)
1317  return errh->error("Encoding[1] out of range"), -EFAULT;
1318  const uint8_t *p = data + pos + 2;
1319  int n = data[pos + 1];
1320  for (int i = 0; i < n; i++, p += 2) {
1321  int first = p[0];
1322  int nLeft = p[1];
1323  for (int e = first; e <= first + nLeft; e++) {
1324  if (_encoding[e])
1325  retval = 1;
1326  _encoding[e] = g++;
1327  }
1328  }
1329 
1330  } else
1331  return errh->error("unknown Encoding format %d", format), -EINVAL;
1332 
1333  if (g > _charset.nglyphs())
1334  return errh->error("Encoding glyph %d out of range", g), -EINVAL;
1335 
1336  // check supplements
1337  if (supplemented) {
1338  if (endpos + data[endpos] * 3 > len)
1339  return -EINVAL;
1340  const uint8_t *p = data + endpos + 1;
1341  int n = data[endpos];
1342  for (int i = 0; i < n; i++, p += 3) {
1343  int e = p[0];
1344  int s = (p[1] << 8) | p[2];
1345  int g = _charset.sid_to_gid(s);
1346  if (_encoding[e])
1347  retval = 1;
1348  if (g < 0 || g >= _charset.nglyphs())
1349  return errh->error("Encoding glyph %d out of range", g), -EINVAL;
1350  _encoding[e] = g;
1351  }
1352  }
1353 
1354  // successfully done
1355  return retval;
1356 }
1357 
1358 int
1360 {
1361  for (int i = 0; i < 256; i++)
1362  _encoding[i] = _charset.sid_to_gid(standard_encoding[i]);
1363  return 0;
1364 }
1365 
1366 void
1368 {
1369  Vector<double> t1d_matrix;
1370  if (dict_value(oFontMatrix, t1d_matrix) && t1d_matrix.size() == 6)
1371  memcpy(&matrix[0], &t1d_matrix[0], sizeof(double) * 6);
1372  else {
1373  matrix[0] = matrix[3] = 0.001;
1374  matrix[1] = matrix[2] = matrix[4] = matrix[5] = 0;
1375  }
1376 }
1377 
1378 PermString
1380 {
1381  if (gid >= 0 && gid < nglyphs())
1382  return _cff->sid_permstring(_charset.gid_to_sid(gid));
1383  else
1384  return PermString();
1385 }
1386 
1387 void
1389 {
1390  gnames.resize(nglyphs());
1391  for (int i = 0; i < nglyphs(); i++)
1392  gnames[i] = _cff->sid_permstring(_charset.gid_to_sid(i));
1393 }
1394 
1395 Charstring *
1396 Cff::Font::glyph(int gid) const
1397 {
1398  if (gid < 0 || gid >= nglyphs())
1399  return 0;
1400  if (!_charstrings_cs[gid])
1401  _charstrings_cs[gid] = charstring(_charstrings_index, gid);
1402  return _charstrings_cs[gid];
1403 }
1404 
1405 Charstring *
1407 {
1408  int gid = _charset.sid_to_gid(_cff->sid(name));
1409  if (gid < 0)
1410  return 0;
1411  if (!_charstrings_cs[gid])
1412  _charstrings_cs[gid] = charstring(_charstrings_index, gid);
1413  return _charstrings_cs[gid];
1414 }
1415 
1416 int
1418 {
1419  return _charset.sid_to_gid(_cff->sid(name));
1420 }
1421 
1422 Type1Encoding *
1424 {
1425  if (_encoding_pos == 0)
1427  if (!_t1encoding)
1428  _t1encoding = type1_encoding_copy();
1429  return _t1encoding;
1430 }
1431 
1432 Type1Encoding *
1434 {
1435  if (_encoding_pos == 0)
1437  Type1Encoding *e = new Type1Encoding;
1438  for (int i = 0; i < 256; i++)
1439  if (_encoding[i])
1440  e->put(i, _cff->sid_permstring(_charset.gid_to_sid(_encoding[i])));
1441  return e;
1442 }
1443 
1444 bool
1446 {
1447  return dict_of(op).has(op);
1448 }
1449 
1450 String
1452 {
1454  dict_of(op).value(op, vec);
1455  if (vec.size() == 1 && vec[0] >= 0 && vec[0] <= _cff->max_sid())
1456  return _cff->sid_string((int) vec[0]);
1457  else
1458  return String();
1459 }
1460 
1461 
1462 /*****
1463  * Cff::CIDFont
1464  **/
1465 
1467  : FontParent(cff), _font_name(font_name), _top_dict(top_dict)
1468 {
1470 
1471  // parse top DICT
1472  _error = -EINVAL;
1473  if (_top_dict.check(false, errh, "Top DICT") < 0)
1474  return;
1475  else if (!_top_dict.has(oCharStrings)) {
1476  errh->error("font has no CharStrings dictionary");
1477  return;
1478  }
1479  //_top_dict.unparse(errh, "Top DICT");
1480 
1481  // extract offsets and information from TOP DICT
1483  if (_charstring_type != 1 && _charstring_type != 2) {
1484  errh->error("unknown CharString type %d", _charstring_type);
1485  return;
1486  }
1487 
1488  int charstrings_offset = 0;
1489  _top_dict.value(oCharStrings, &charstrings_offset);
1490  _charstrings_index = Cff::IndexIterator(cff->data(), charstrings_offset, cff->length(), errh, "CharStrings INDEX");
1491  if (_charstrings_index.error() < 0) {
1493  return;
1494  }
1496 
1497  int charset = 0;
1500  if (_charset.error() < 0) {
1501  _error = _charset.error();
1502  return;
1503  }
1504 
1505  // extract information about child fonts
1506  int fdarray_offset = 0;
1507  if (!_top_dict.value(oFDArray, &fdarray_offset)) {
1508  errh->error("CID-keyed font missing FDArray");
1509  return;
1510  }
1511  IndexIterator fdarray_index(cff->data(), fdarray_offset, cff->length(), errh, "FDArray INDEX");
1512  for (; fdarray_index; fdarray_index++) {
1513  Dict d(cff, fdarray_index[0] - cff->data(), fdarray_index[1] - fdarray_index[0], errh, "Top DICT");
1514  if (!d.ok() || d.check(false, errh, "Top DICT") < 0) {
1515  _error = d.error();
1516  return;
1517  }
1518  _child_fonts.push_back(new ChildFont(cff, this, _charstring_type, d, errh));
1519  if (!_child_fonts.back()->ok())
1520  return;
1521  }
1522 
1523  int fdselect_offset = 0;
1524  if (!_top_dict.value(oFDSelect, &fdselect_offset)) {
1525  errh->error("CID-keyed font missing FDSelect");
1526  return;
1527  }
1528  _fdselect.assign(cff, fdselect_offset, _charstrings_cs.size(), errh);
1529  if (_fdselect.error() < 0)
1530  return;
1531 
1532  // success!
1533  _error = 0;
1534  set_parent_program(true);
1535 }
1536 
1538 {
1539  for (int i = 0; i < _charstrings_cs.size(); i++)
1540  delete _charstrings_cs[i];
1541  for (int i = 0; i < _child_fonts.size(); i++)
1542  delete _child_fonts[i];
1543 }
1544 
1545 void
1547 {
1548  // XXX
1549  matrix[0] = matrix[3] = 0.001;
1550  matrix[1] = matrix[2] = matrix[4] = matrix[5] = 0;
1551 }
1552 
1553 const CharstringProgram *
1555 {
1556  int fd = _fdselect.gid_to_fd(gid);
1557  if (fd >= 0 && fd < _child_fonts.size())
1558  return _child_fonts.at_u(fd);
1559  else
1560  return 0;
1561 }
1562 
1563 PermString
1565 {
1566  if (gid >= 0 && gid < nglyphs())
1567  return permprintf("#%d", _charset.gid_to_sid(gid));
1568  else
1569  return PermString();
1570 }
1571 
1572 void
1574 {
1575  gnames.resize(nglyphs());
1576  for (int i = 0; i < nglyphs(); i++)
1577  gnames[i] = permprintf("#%d", _charset.gid_to_sid(i));
1578 }
1579 
1580 Charstring *
1581 Cff::CIDFont::glyph(int gid) const
1582 {
1583  if (gid < 0 || gid >= nglyphs())
1584  return 0;
1585  if (!_charstrings_cs[gid])
1586  _charstrings_cs[gid] = charstring(_charstrings_index, gid);
1587  return _charstrings_cs[gid];
1588 }
1589 
1590 int
1592 {
1593  if (name.length() <= 1 || name[0] != '#' || !isdigit((unsigned char) name[1]))
1594  return -1;
1595  char *endptr;
1596  long cid = strtol(name.c_str() + 1, &endptr, 10);
1597  if (*endptr != 0)
1598  return -1;
1599  return _charset.sid_to_gid(cid);
1600 }
1601 
1602 Charstring *
1604 {
1606 }
1607 
1608 
1609 /*****
1610  * ChildFont
1611  **/
1612 
1613 Cff::ChildFont::ChildFont(Cff *cff, Cff::CIDFont *parent, int charstring_type, const Dict &top_dict, ErrorHandler *errh)
1614  : FontParent(cff), _parent(parent), _top_dict(top_dict)
1615 {
1616  if (!errh)
1618 
1619  if (!cff->ok() || !_top_dict.ok()) {
1620  errh->error("invalid CFF");
1621  _error = -EINVAL;
1622  return;
1623  }
1624 
1625  // extract offsets and information from TOP DICT
1626  _charstring_type = charstring_type;
1628  if (_charstring_type != 1 && _charstring_type != 2) {
1629  errh->error("unknown CharString type %d", _charstring_type);
1630  return;
1631  }
1632 
1633  // extract information from Private DICT
1634  if (_top_dict.has(oPrivate)
1636  return;
1637 
1638  // success!
1639  _error = 0;
1640 }
1641 
1643 {
1644  for (int i = 0; i < _subrs_cs.size(); i++)
1645  delete _subrs_cs[i];
1646 }
1647 
1648 Charstring *
1649 Cff::ChildFont::charstring(const IndexIterator &iiter, int which) const
1650 {
1651  const uint8_t *s1 = iiter[which];
1652  int slen = iiter[which + 1] - s1;
1653  String cs = _cff->data_string().substring(s1 - _cff->data(), slen);
1654  if (slen == 0)
1655  return 0;
1656  else if (_charstring_type == 1)
1657  return new Type1Charstring(cs);
1658  else
1659  return new Type2Charstring(cs);
1660 }
1661 
1662 Charstring *
1664 {
1665  i += Efont::subr_bias(_charstring_type, nsubrs_x());
1666  if (i < 0 || i >= nsubrs_x())
1667  return 0;
1668  if (!_subrs_cs[i])
1669  _subrs_cs[i] = charstring(_subrs_index, i);
1670  return _subrs_cs[i];
1671 }
1672 
1673 int
1675 {
1676  return Efont::subr_bias(_charstring_type, nsubrs_x());
1677 }
1678 
1679 double
1680 Cff::ChildFont::global_width_x(bool is_nominal) const
1681 {
1682  return (is_nominal ? _nominal_width_x : _default_width_x);
1683 }
1684 
1685 }
double __cdecl strtod(char const *_String, char **_EndPtr)
long __cdecl strtol(char const *_String, char **_EndPtr, int _Radix)
return _Result< 0 ? -1 :_Result;} #line 1069 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _vsnwprintf_s_l(wchar_t *const _Buffer, size_t const _BufferCount, size_t const _MaxCount, wchar_t const *const _Format, _locale_t const _Locale, va_list _ArgList) { int const _Result=__stdio_common_vsnwprintf_s((*__local_stdio_printf_options()), _Buffer, _BufferCount, _MaxCount, _Format, _Locale, _ArgList);return _Result< 0 ? -1 :_Result;} #line 1091 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _vsnwprintf_s(wchar_t *const _Buffer, size_t const _BufferCount, size_t const _MaxCount, wchar_t const *const _Format, va_list _ArgList) { return _vsnwprintf_s_l(_Buffer, _BufferCount, _MaxCount, _Format,((void *) 0), _ArgList);} #line 1108 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __declspec(deprecated("This function or variable may be unsafe. Consider using " "_snwprintf_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl _snwprintf(wchar_t *_Buffer, size_t _BufferCount, wchar_t const *_Format,...);__declspec(deprecated("This function or variable may be unsafe. Consider using " "_vsnwprintf_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl _vsnwprintf(wchar_t *_Buffer, size_t _BufferCount, wchar_t const *_Format, va_list _Args);__declspec(deprecated("This function or variable may be unsafe. Consider using " "_vsnwprintf_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl _vsnwprintf(wchar_t *_Buffer, size_t _BufferCount, wchar_t const *_Format, va_list _ArgList) { return _vsnwprintf_l(_Buffer, _BufferCount, _Format,((void *) 0), _ArgList);} #line 1133 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _vswprintf_c_l(wchar_t *const _Buffer, size_t const _BufferCount, wchar_t const *const _Format, _locale_t const _Locale, va_list _ArgList) { int const _Result=__stdio_common_vswprintf((*__local_stdio_printf_options()), _Buffer, _BufferCount, _Format, _Locale, _ArgList);return _Result< 0 ? -1 :_Result;} #line 1163 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _vswprintf_c(wchar_t *const _Buffer, size_t const _BufferCount, wchar_t const *const _Format, va_list _ArgList) { return _vswprintf_c_l(_Buffer, _BufferCount, _Format,((void *) 0), _ArgList);} #line 1179 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _vswprintf_l(wchar_t *const _Buffer, size_t const _BufferCount, wchar_t const *const _Format, _locale_t const _Locale, va_list _ArgList) { return _vswprintf_c_l(_Buffer, _BufferCount, _Format, _Locale, _ArgList);} #line 1196 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl __vswprintf_l(wchar_t *const _Buffer, wchar_t const *const _Format, _locale_t const _Locale, va_list _ArgList) { return _vswprintf_l(_Buffer,(size_t) -1, _Format, _Locale, _ArgList);} #line 1212 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _vswprintf(wchar_t *const _Buffer, wchar_t const *const _Format, va_list _ArgList) { return _vswprintf_l(_Buffer,(size_t) -1, _Format,((void *) 0), _ArgList);} #line 1227 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl vswprintf(wchar_t *const _Buffer, size_t const _BufferCount, wchar_t const *const _Format, va_list _ArgList) { return _vswprintf_c_l(_Buffer, _BufferCount, _Format,((void *) 0), _ArgList);} #line 1243 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _vswprintf_s_l(wchar_t *const _Buffer, size_t const _BufferCount, wchar_t const *const _Format, _locale_t const _Locale, va_list _ArgList) { int const _Result=__stdio_common_vswprintf_s((*__local_stdio_printf_options()), _Buffer, _BufferCount, _Format, _Locale, _ArgList);return _Result< 0 ? -1 :_Result;} #line 1264 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl vswprintf_s(wchar_t *const _Buffer, size_t const _BufferCount, wchar_t const *const _Format, va_list _ArgList) { return _vswprintf_s_l(_Buffer, _BufferCount, _Format,((void *) 0), _ArgList);} #line 1281 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" #line 1283 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _vswprintf_p_l(wchar_t *const _Buffer, size_t const _BufferCount, wchar_t const *const _Format, _locale_t const _Locale, va_list _ArgList) { int const _Result=__stdio_common_vswprintf_p((*__local_stdio_printf_options()), _Buffer, _BufferCount, _Format, _Locale, _ArgList);return _Result< 0 ? -1 :_Result;} #line 1312 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _vswprintf_p(wchar_t *const _Buffer, size_t const _BufferCount, wchar_t const *const _Format, va_list _ArgList) { return _vswprintf_p_l(_Buffer, _BufferCount, _Format,((void *) 0), _ArgList);} #line 1328 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _vscwprintf_l(wchar_t const *const _Format, _locale_t const _Locale, va_list _ArgList) { int const _Result=__stdio_common_vswprintf((*__local_stdio_printf_options())|(1ULL<< 1),((void *) 0), 0, _Format, _Locale, _ArgList);return _Result< 0 ? -1 :_Result;} #line 1347 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _vscwprintf(wchar_t const *const _Format, va_list _ArgList) { return _vscwprintf_l(_Format,((void *) 0), _ArgList);} #line 1361 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _vscwprintf_p_l(wchar_t const *const _Format, _locale_t const _Locale, va_list _ArgList) { int const _Result=__stdio_common_vswprintf_p((*__local_stdio_printf_options())|(1ULL<< 1),((void *) 0), 0, _Format, _Locale, _ArgList);return _Result< 0 ? -1 :_Result;} #line 1380 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _vscwprintf_p(wchar_t const *const _Format, va_list _ArgList) { return _vscwprintf_p_l(_Format,((void *) 0), _ArgList);} #line 1394 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl __swprintf_l(wchar_t *const _Buffer, wchar_t const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=__vswprintf_l(_Buffer, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1414 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _swprintf_l(wchar_t *const _Buffer, size_t const _BufferCount, wchar_t const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vswprintf_c_l(_Buffer, _BufferCount, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1435 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _swprintf(wchar_t *const _Buffer, wchar_t const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=__vswprintf_l(_Buffer, _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1454 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl swprintf(wchar_t *const _Buffer, size_t const _BufferCount, wchar_t const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vswprintf_c_l(_Buffer, _BufferCount, _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1474 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __declspec(deprecated("This function or variable may be unsafe. Consider using " "__swprintf_l_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl __swprintf_l(wchar_t *_Buffer, wchar_t const *_Format, _locale_t _Locale,...);__declspec(deprecated("This function or variable may be unsafe. Consider using " "_vswprintf_s_l" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl __vswprintf_l(wchar_t *_Buffer, wchar_t const *_Format, _locale_t _Locale, va_list _Args);__declspec(deprecated("This function or variable may be unsafe. Consider using " "swprintf_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl _swprintf(wchar_t *_Buffer, wchar_t const *_Format,...);__declspec(deprecated("This function or variable may be unsafe. Consider using " "vswprintf_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl _vswprintf(wchar_t *_Buffer, wchar_t const *_Format, va_list _Args);__inline int __cdecl _swprintf_s_l(wchar_t *const _Buffer, size_t const _BufferCount, wchar_t const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vswprintf_s_l(_Buffer, _BufferCount, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1511 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl swprintf_s(wchar_t *const _Buffer, size_t const _BufferCount, wchar_t const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vswprintf_s_l(_Buffer, _BufferCount, _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1532 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" #line 1534 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _swprintf_p_l(wchar_t *const _Buffer, size_t const _BufferCount, wchar_t const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vswprintf_p_l(_Buffer, _BufferCount, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1562 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _swprintf_p(wchar_t *const _Buffer, size_t const _BufferCount, wchar_t const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vswprintf_p_l(_Buffer, _BufferCount, _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1582 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _swprintf_c_l(wchar_t *const _Buffer, size_t const _BufferCount, wchar_t const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vswprintf_c_l(_Buffer, _BufferCount, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1603 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _swprintf_c(wchar_t *const _Buffer, size_t const _BufferCount, wchar_t const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vswprintf_c_l(_Buffer, _BufferCount, _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1623 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __declspec(deprecated("This function or variable may be unsafe. Consider using " "_snwprintf_s_l" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl _snwprintf_l(wchar_t *const _Buffer, size_t const _BufferCount, wchar_t const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vsnwprintf_l(_Buffer, _BufferCount, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1646 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _snwprintf(wchar_t *_Buffer, size_t _BufferCount, wchar_t const *_Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vsnwprintf_l(_Buffer, _BufferCount, _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1668 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _snwprintf_s_l(wchar_t *const _Buffer, size_t const _BufferCount, size_t const _MaxCount, wchar_t const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vsnwprintf_s_l(_Buffer, _BufferCount, _MaxCount, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1690 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _snwprintf_s(wchar_t *const _Buffer, size_t const _BufferCount, size_t const _MaxCount, wchar_t const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vsnwprintf_s_l(_Buffer, _BufferCount, _MaxCount, _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1711 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _scwprintf_l(wchar_t const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vscwprintf_l(_Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1737 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _scwprintf(wchar_t const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vscwprintf_l(_Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1755 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _scwprintf_p_l(wchar_t const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vscwprintf_p_l(_Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1774 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _scwprintf_p(wchar_t const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vscwprintf_p_l(_Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1792 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" #pragma warning(push) #pragma warning(disable:4141 6054) #pragma warning(pop) #line 1856 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" int __cdecl __stdio_common_vswscanf(unsigned __int64 _Options, wchar_t const *_Buffer, size_t _BufferCount, wchar_t const *_Format, _locale_t _Locale, va_list _ArgList);__inline int __cdecl _vswscanf_l(wchar_t const *const _Buffer, wchar_t const *const _Format, _locale_t const _Locale, va_list _ArgList) { return __stdio_common_vswscanf((*__local_stdio_scanf_options()), _Buffer,(size_t) -1, _Format, _Locale, _ArgList);} #line 1897 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl vswscanf(wchar_t const *_Buffer, wchar_t const *_Format, va_list _ArgList) { return _vswscanf_l(_Buffer, _Format,((void *) 0), _ArgList);} #line 1912 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _vswscanf_s_l(wchar_t const *const _Buffer, wchar_t const *const _Format, _locale_t const _Locale, va_list _ArgList) { return __stdio_common_vswscanf((*__local_stdio_scanf_options())|(1ULL<< 0), _Buffer,(size_t) -1, _Format, _Locale, _ArgList);} #line 1930 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl vswscanf_s(wchar_t const *const _Buffer, wchar_t const *const _Format, va_list _ArgList) { return _vswscanf_s_l(_Buffer, _Format,((void *) 0), _ArgList);} #line 1947 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" #line 1949 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __declspec(deprecated("This function or variable may be unsafe. Consider using " "_vsnwscanf_s_l" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl _vsnwscanf_l(wchar_t const *const _Buffer, size_t const _BufferCount, wchar_t const *const _Format, _locale_t const _Locale, va_list _ArgList) { return __stdio_common_vswscanf((*__local_stdio_scanf_options()), _Buffer, _BufferCount, _Format, _Locale, _ArgList);} #line 1976 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _vsnwscanf_s_l(wchar_t const *const _Buffer, size_t const _BufferCount, wchar_t const *const _Format, _locale_t const _Locale, va_list _ArgList) { return __stdio_common_vswscanf((*__local_stdio_scanf_options())|(1ULL<< 0), _Buffer, _BufferCount, _Format, _Locale, _ArgList);} #line 1995 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __declspec(deprecated("This function or variable may be unsafe. Consider using " "_swscanf_s_l" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl _swscanf_l(wchar_t const *const _Buffer, wchar_t const *const _Format, _locale_t _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vswscanf_l(_Buffer, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 2015 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __declspec(deprecated("This function or variable may be unsafe. Consider using " "swscanf_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl swscanf(wchar_t const *const _Buffer, wchar_t const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vswscanf_l(_Buffer, _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 2034 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _swscanf_s_l(wchar_t const *const _Buffer, wchar_t const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vswscanf_s_l(_Buffer, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 2054 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl swscanf_s(wchar_t const *const _Buffer, wchar_t const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vswscanf_s_l(_Buffer, _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 2075 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" #line 2077 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __declspec(deprecated("This function or variable may be unsafe. Consider using " "_snwscanf_s_l" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl _snwscanf_l(wchar_t const *const _Buffer, size_t const _BufferCount, wchar_t const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vsnwscanf_l(_Buffer, _BufferCount, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 2100 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __declspec(deprecated("This function or variable may be unsafe. Consider using " "_snwscanf_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl _snwscanf(wchar_t const *const _Buffer, size_t const _BufferCount, wchar_t const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vsnwscanf_l(_Buffer, _BufferCount, _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 2122 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _snwscanf_s_l(wchar_t const *const _Buffer, size_t const _BufferCount, wchar_t const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vsnwscanf_s_l(_Buffer, _BufferCount, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 2143 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __inline int __cdecl _snwscanf_s(wchar_t const *const _Buffer, size_t const _BufferCount, wchar_t const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vsnwscanf_s_l(_Buffer, _BufferCount, _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 2163 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstdio.h" __pragma(pack(pop))#pragma warning(pop) #pragma warning(push)#pragma warning(disable:4324 4514 4574 4710 4793 4820 4995 4996 28719 28726 28727) __pragma(pack(push, 8)) typedef __int64 fpos_t;errno_t __cdecl _get_stream_buffer_pointers(FILE *_Stream, char ***_Base, char ***_Pointer, int **_Count);errno_t __cdecl clearerr_s(FILE *_Stream);errno_t __cdecl fopen_s(FILE **_Stream, char const *_FileName, char const *_Mode);size_t __cdecl fread_s(void *_Buffer, size_t _BufferSize, size_t _ElementSize, size_t _ElementCount, FILE *_Stream);errno_t __cdecl freopen_s(FILE **_Stream, char const *_FileName, char const *_Mode, FILE *_OldStream);char *__cdecl gets_s(char *_Buffer, rsize_t _Size);errno_t __cdecl tmpfile_s(FILE **_Stream);errno_t __cdecl tmpnam_s(char *_Buffer, rsize_t _Size);#line 145 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" void __cdecl clearerr(FILE *_Stream);int __cdecl fclose(FILE *_Stream);int __cdecl _fcloseall(void);FILE *__cdecl _fdopen(int _FileHandle, char const *_Mode);int __cdecl feof(FILE *_Stream);int __cdecl ferror(FILE *_Stream);int __cdecl fflush(FILE *_Stream);int __cdecl fgetc(FILE *_Stream);int __cdecl _fgetchar(void);int __cdecl fgetpos(FILE *_Stream, fpos_t *_Position);char *__cdecl fgets(char *_Buffer, int _MaxCount, FILE *_Stream);int __cdecl _fileno(FILE *_Stream);int __cdecl _flushall(void);__declspec(deprecated("This function or variable may be unsafe. Consider using " "fopen_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) FILE *__cdecl fopen(char const *_FileName, char const *_Mode);int __cdecl fputc(int _Character, FILE *_Stream);int __cdecl _fputchar(int _Character);int __cdecl fputs(char const *_Buffer, FILE *_Stream);size_t __cdecl fread(void *_Buffer, size_t _ElementSize, size_t _ElementCount, FILE *_Stream);__declspec(deprecated("This function or variable may be unsafe. Consider using " "freopen_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) FILE *__cdecl freopen(char const *_FileName, char const *_Mode, FILE *_Stream);FILE *__cdecl _fsopen(char const *_FileName, char const *_Mode, int _ShFlag);int __cdecl fsetpos(FILE *_Stream, fpos_t const *_Position);int __cdecl fseek(FILE *_Stream, long _Offset, int _Origin);int __cdecl _fseeki64(FILE *_Stream, __int64 _Offset, int _Origin);long __cdecl ftell(FILE *_Stream);__int64 __cdecl _ftelli64(FILE *_Stream);size_t __cdecl fwrite(void const *_Buffer, size_t _ElementSize, size_t _ElementCount, FILE *_Stream);int __cdecl getc(FILE *_Stream);int __cdecl getchar(void);int __cdecl _getmaxstdio(void);int __cdecl _getw(FILE *_Stream);void __cdecl perror(char const *_ErrorMessage);int __cdecl _pclose(FILE *_Stream);FILE *__cdecl _popen(char const *_Command, char const *_Mode);#line 344 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" int __cdecl putc(int _Character, FILE *_Stream);int __cdecl putchar(int _Character);int __cdecl puts(char const *_Buffer);int __cdecl _putw(int _Word, FILE *_Stream);int __cdecl remove(char const *_FileName);int __cdecl rename(char const *_OldFileName, char const *_NewFileName);int __cdecl _unlink(char const *_FileName);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_unlink" ". See online help for details.")) int __cdecl unlink(char const *_FileName);#line 391 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" void __cdecl rewind(FILE *_Stream);int __cdecl _rmtmp(void);__declspec(deprecated("This function or variable may be unsafe. Consider using " "setvbuf" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) void __cdecl setbuf(FILE *_Stream, char *_Buffer);int __cdecl _setmaxstdio(int _Maximum);int __cdecl setvbuf(FILE *_Stream, char *_Buffer, int _Mode, size_t _Size);__declspec(allocator) char *__cdecl _tempnam(char const *_DirectoryName, char const *_FilePrefix);__declspec(deprecated("This function or variable may be unsafe. Consider using " "tmpfile_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) FILE *__cdecl tmpfile(void);__declspec(deprecated("This function or variable may be unsafe. Consider using " "tmpnam_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) char *__cdecl tmpnam(char *_Buffer);int __cdecl ungetc(int _Character, FILE *_Stream);void __cdecl _lock_file(FILE *_Stream);void __cdecl _unlock_file(FILE *_Stream);int __cdecl _fclose_nolock(FILE *_Stream);int __cdecl _fflush_nolock(FILE *_Stream);int __cdecl _fgetc_nolock(FILE *_Stream);int __cdecl _fputc_nolock(int _Character, FILE *_Stream);size_t __cdecl _fread_nolock(void *_Buffer, size_t _ElementSize, size_t _ElementCount, FILE *_Stream);size_t __cdecl _fread_nolock_s(void *_Buffer, size_t _BufferSize, size_t _ElementSize, size_t _ElementCount, FILE *_Stream);int __cdecl _fseek_nolock(FILE *_Stream, long _Offset, int _Origin);int __cdecl _fseeki64_nolock(FILE *_Stream, __int64 _Offset, int _Origin);long __cdecl _ftell_nolock(FILE *_Stream);__int64 __cdecl _ftelli64_nolock(FILE *_Stream);size_t __cdecl _fwrite_nolock(void const *_Buffer, size_t _ElementSize, size_t _ElementCount, FILE *_Stream);int __cdecl _getc_nolock(FILE *_Stream);int __cdecl _putc_nolock(int _Character, FILE *_Stream);int __cdecl _ungetc_nolock(int _Character, FILE *_Stream);int *__cdecl __p__commode(void);#line 596 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" int __cdecl __stdio_common_vfprintf(unsigned __int64 _Options, FILE *_Stream, char const *_Format, _locale_t _Locale, va_list _ArgList);int __cdecl __stdio_common_vfprintf_s(unsigned __int64 _Options, FILE *_Stream, char const *_Format, _locale_t _Locale, va_list _ArgList);int __cdecl __stdio_common_vfprintf_p(unsigned __int64 _Options, FILE *_Stream, char const *_Format, _locale_t _Locale, va_list _ArgList);__inline int __cdecl _vfprintf_l(FILE *const _Stream, char const *const _Format, _locale_t const _Locale, va_list _ArgList) { return __stdio_common_vfprintf((*__local_stdio_printf_options()), _Stream, _Format, _Locale, _ArgList);} #line 648 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl vfprintf(FILE *const _Stream, char const *const _Format, va_list _ArgList) { return _vfprintf_l(_Stream, _Format,((void *) 0), _ArgList);} #line 662 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _vfprintf_s_l(FILE *const _Stream, char const *const _Format, _locale_t const _Locale, va_list _ArgList) { return __stdio_common_vfprintf_s((*__local_stdio_printf_options()), _Stream, _Format, _Locale, _ArgList);} #line 677 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl vfprintf_s(FILE *const _Stream, char const *const _Format, va_list _ArgList) { return _vfprintf_s_l(_Stream, _Format,((void *) 0), _ArgList);} #line 693 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" #line 695 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _vfprintf_p_l(FILE *const _Stream, char const *const _Format, _locale_t const _Locale, va_list _ArgList) { return __stdio_common_vfprintf_p((*__local_stdio_printf_options()), _Stream, _Format, _Locale, _ArgList);} #line 710 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _vfprintf_p(FILE *const _Stream, char const *const _Format, va_list _ArgList) { return _vfprintf_p_l(_Stream, _Format,((void *) 0), _ArgList);} #line 724 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _vprintf_l(char const *const _Format, _locale_t const _Locale, va_list _ArgList) { return _vfprintf_l((__acrt_iob_func(1)), _Format, _Locale, _ArgList);} #line 738 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl vprintf(char const *const _Format, va_list _ArgList) { return _vfprintf_l((__acrt_iob_func(1)), _Format,((void *) 0), _ArgList);} #line 751 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _vprintf_s_l(char const *const _Format, _locale_t const _Locale, va_list _ArgList) { return _vfprintf_s_l((__acrt_iob_func(1)), _Format, _Locale, _ArgList);} #line 765 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl vprintf_s(char const *const _Format, va_list _ArgList) { return _vfprintf_s_l((__acrt_iob_func(1)), _Format,((void *) 0), _ArgList);} #line 780 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" #line 782 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _vprintf_p_l(char const *const _Format, _locale_t const _Locale, va_list _ArgList) { return _vfprintf_p_l((__acrt_iob_func(1)), _Format, _Locale, _ArgList);} #line 796 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _vprintf_p(char const *const _Format, va_list _ArgList) { return _vfprintf_p_l((__acrt_iob_func(1)), _Format,((void *) 0), _ArgList);} #line 809 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _fprintf_l(FILE *const _Stream, char const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vfprintf_l(_Stream, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 828 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl fprintf(FILE *const _Stream, char const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vfprintf_l(_Stream, _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 846 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" int __cdecl _set_printf_count_output(int _Value);int __cdecl _get_printf_count_output(void);__inline int __cdecl _fprintf_s_l(FILE *const _Stream, char const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vfprintf_s_l(_Stream, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 871 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl fprintf_s(FILE *const _Stream, char const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vfprintf_s_l(_Stream, _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 891 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" #line 893 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _fprintf_p_l(FILE *const _Stream, char const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vfprintf_p_l(_Stream, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 912 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _fprintf_p(FILE *const _Stream, char const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vfprintf_p_l(_Stream, _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 930 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _printf_l(char const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vfprintf_l((__acrt_iob_func(1)), _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 948 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl printf(char const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vfprintf_l((__acrt_iob_func(1)), _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 965 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _printf_s_l(char const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vfprintf_s_l((__acrt_iob_func(1)), _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 983 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl printf_s(char const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vfprintf_s_l((__acrt_iob_func(1)), _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1002 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" #line 1004 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _printf_p_l(char const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vfprintf_p_l((__acrt_iob_func(1)), _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1022 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _printf_p(char const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vfprintf_p_l((__acrt_iob_func(1)), _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1039 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" int __cdecl __stdio_common_vfscanf(unsigned __int64 _Options, FILE *_Stream, char const *_Format, _locale_t _Locale, va_list _Arglist);__inline int __cdecl _vfscanf_l(FILE *const _Stream, char const *const _Format, _locale_t const _Locale, va_list _ArgList) { return __stdio_common_vfscanf((*__local_stdio_scanf_options()), _Stream, _Format, _Locale, _ArgList);} #line 1070 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl vfscanf(FILE *const _Stream, char const *const _Format, va_list _ArgList) { return _vfscanf_l(_Stream, _Format,((void *) 0), _ArgList);} #line 1084 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _vfscanf_s_l(FILE *const _Stream, char const *const _Format, _locale_t const _Locale, va_list _ArgList) { return __stdio_common_vfscanf((*__local_stdio_scanf_options())|(1ULL<< 0), _Stream, _Format, _Locale, _ArgList);} #line 1101 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl vfscanf_s(FILE *const _Stream, char const *const _Format, va_list _ArgList) { return _vfscanf_s_l(_Stream, _Format,((void *) 0), _ArgList);} #line 1118 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" #line 1120 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _vscanf_l(char const *const _Format, _locale_t const _Locale, va_list _ArgList) { return _vfscanf_l((__acrt_iob_func(0)), _Format, _Locale, _ArgList);} #line 1134 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl vscanf(char const *const _Format, va_list _ArgList) { return _vfscanf_l((__acrt_iob_func(0)), _Format,((void *) 0), _ArgList);} #line 1147 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _vscanf_s_l(char const *const _Format, _locale_t const _Locale, va_list _ArgList) { return _vfscanf_s_l((__acrt_iob_func(0)), _Format, _Locale, _ArgList);} #line 1161 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl vscanf_s(char const *const _Format, va_list _ArgList) { return _vfscanf_s_l((__acrt_iob_func(0)), _Format,((void *) 0), _ArgList);} #line 1176 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" #line 1178 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __declspec(deprecated("This function or variable may be unsafe. Consider using " "_fscanf_s_l" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl _fscanf_l(FILE *const _Stream, char const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vfscanf_l(_Stream, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1197 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __declspec(deprecated("This function or variable may be unsafe. Consider using " "fscanf_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl fscanf(FILE *const _Stream, char const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vfscanf_l(_Stream, _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1215 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _fscanf_s_l(FILE *const _Stream, char const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vfscanf_s_l(_Stream, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1234 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl fscanf_s(FILE *const _Stream, char const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vfscanf_s_l(_Stream, _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1254 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" #line 1256 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __declspec(deprecated("This function or variable may be unsafe. Consider using " "_scanf_s_l" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl _scanf_l(char const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vfscanf_l((__acrt_iob_func(0)), _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1274 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __declspec(deprecated("This function or variable may be unsafe. Consider using " "scanf_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl scanf(char const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vfscanf_l((__acrt_iob_func(0)), _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1291 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _scanf_s_l(char const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vfscanf_s_l((__acrt_iob_func(0)), _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1309 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl scanf_s(char const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vfscanf_s_l((__acrt_iob_func(0)), _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1328 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" #line 1330 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" int __cdecl __stdio_common_vsprintf(unsigned __int64 _Options, char *_Buffer, size_t _BufferCount, char const *_Format, _locale_t _Locale, va_list _ArgList);int __cdecl __stdio_common_vsprintf_s(unsigned __int64 _Options, char *_Buffer, size_t _BufferCount, char const *_Format, _locale_t _Locale, va_list _ArgList);int __cdecl __stdio_common_vsnprintf_s(unsigned __int64 _Options, char *_Buffer, size_t _BufferCount, size_t _MaxCount, char const *_Format, _locale_t _Locale, va_list _ArgList);int __cdecl __stdio_common_vsprintf_p(unsigned __int64 _Options, char *_Buffer, size_t _BufferCount, char const *_Format, _locale_t _Locale, va_list _ArgList);__declspec(deprecated("This function or variable may be unsafe. Consider using " "_vsnprintf_s_l" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl _vsnprintf_l(char *const _Buffer, size_t const _BufferCount, char const *const _Format, _locale_t const _Locale, va_list _ArgList) { int const _Result=__stdio_common_vsprintf((*__local_stdio_printf_options())|(1ULL<< 0), _Buffer, _BufferCount, _Format, _Locale, _ArgList);return _Result< 0 ? -1 :_Result;} #line 1399 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _vsnprintf(char *const _Buffer, size_t const _BufferCount, char const *const _Format, va_list _ArgList) { return _vsnprintf_l(_Buffer, _BufferCount, _Format,((void *) 0), _ArgList);} #line 1415 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl vsnprintf(char *const _Buffer, size_t const _BufferCount, char const *const _Format, va_list _ArgList) { int const _Result=__stdio_common_vsprintf((*__local_stdio_printf_options())|(1ULL<< 1), _Buffer, _BufferCount, _Format,((void *) 0), _ArgList);return _Result< 0 ? -1 :_Result;} #line 1446 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __declspec(deprecated("This function or variable may be unsafe. Consider using " "_vsprintf_s_l" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl _vsprintf_l(char *const _Buffer, char const *const _Format, _locale_t const _Locale, va_list _ArgList) { return _vsnprintf_l(_Buffer,(size_t) -1, _Format, _Locale, _ArgList);} #line 1462 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __declspec(deprecated("This function or variable may be unsafe. Consider using " "vsprintf_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl vsprintf(char *const _Buffer, char const *const _Format, va_list _ArgList) { return _vsnprintf_l(_Buffer,(size_t) -1, _Format,((void *) 0), _ArgList);} #line 1477 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _vsprintf_s_l(char *const _Buffer, size_t const _BufferCount, char const *const _Format, _locale_t const _Locale, va_list _ArgList) { int const _Result=__stdio_common_vsprintf_s((*__local_stdio_printf_options()), _Buffer, _BufferCount, _Format, _Locale, _ArgList);return _Result< 0 ? -1 :_Result;} #line 1498 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl vsprintf_s(char *const _Buffer, size_t const _BufferCount, char const *const _Format, va_list _ArgList) { return _vsprintf_s_l(_Buffer, _BufferCount, _Format,((void *) 0), _ArgList);} #line 1516 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" #line 1526 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _vsprintf_p_l(char *const _Buffer, size_t const _BufferCount, char const *const _Format, _locale_t const _Locale, va_list _ArgList) { int const _Result=__stdio_common_vsprintf_p((*__local_stdio_printf_options()), _Buffer, _BufferCount, _Format, _Locale, _ArgList);return _Result< 0 ? -1 :_Result;} #line 1547 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _vsprintf_p(char *const _Buffer, size_t const _BufferCount, char const *const _Format, va_list _ArgList) { return _vsprintf_p_l(_Buffer, _BufferCount, _Format,((void *) 0), _ArgList);} #line 1563 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _vsnprintf_s_l(char *const _Buffer, size_t const _BufferCount, size_t const _MaxCount, char const *const _Format, _locale_t const _Locale, va_list _ArgList) { int const _Result=__stdio_common_vsnprintf_s((*__local_stdio_printf_options()), _Buffer, _BufferCount, _MaxCount, _Format, _Locale, _ArgList);return _Result< 0 ? -1 :_Result;} #line 1585 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _vsnprintf_s(char *const _Buffer, size_t const _BufferCount, size_t const _MaxCount, char const *const _Format, va_list _ArgList) { return _vsnprintf_s_l(_Buffer, _BufferCount, _MaxCount, _Format,((void *) 0), _ArgList);} #line 1602 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl vsnprintf_s(char *const _Buffer, size_t const _BufferCount, size_t const _MaxCount, char const *const _Format, va_list _ArgList) { return _vsnprintf_s_l(_Buffer, _BufferCount, _MaxCount, _Format,((void *) 0), _ArgList);} #line 1630 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" #line 1641 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _vscprintf_l(char const *const _Format, _locale_t const _Locale, va_list _ArgList) { int const _Result=__stdio_common_vsprintf((*__local_stdio_printf_options())|(1ULL<< 1),((void *) 0), 0, _Format, _Locale, _ArgList);return _Result< 0 ? -1 :_Result;} #line 1659 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _vscprintf(char const *const _Format, va_list _ArgList) { return _vscprintf_l(_Format,((void *) 0), _ArgList);} #line 1672 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _vscprintf_p_l(char const *const _Format, _locale_t const _Locale, va_list _ArgList) { int const _Result=__stdio_common_vsprintf_p((*__local_stdio_printf_options())|(1ULL<< 1),((void *) 0), 0, _Format, _Locale, _ArgList);return _Result< 0 ? -1 :_Result;} #line 1690 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _vscprintf_p(char const *const _Format, va_list _ArgList) { return _vscprintf_p_l(_Format,((void *) 0), _ArgList);} #line 1703 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _vsnprintf_c_l(char *const _Buffer, size_t const _BufferCount, char const *const _Format, _locale_t const _Locale, va_list _ArgList) { int const _Result=__stdio_common_vsprintf((*__local_stdio_printf_options()), _Buffer, _BufferCount, _Format, _Locale, _ArgList);return _Result< 0 ? -1 :_Result;} #line 1723 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _vsnprintf_c(char *const _Buffer, size_t const _BufferCount, char const *const _Format, va_list _ArgList) { return _vsnprintf_c_l(_Buffer, _BufferCount, _Format,((void *) 0), _ArgList);} #line 1739 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __declspec(deprecated("This function or variable may be unsafe. Consider using " "_sprintf_s_l" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl _sprintf_l(char *const _Buffer, char const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vsprintf_l(_Buffer, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1761 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl sprintf(char *const _Buffer, char const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vsprintf_l(_Buffer, _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1782 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __declspec(deprecated("This function or variable may be unsafe. Consider using " "sprintf_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) int __cdecl sprintf(char *_Buffer, char const *_Format,...);__declspec(deprecated("This function or variable may be unsafe. Consider using " "vsprintf_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) int __cdecl vsprintf(char *_Buffer, char const *_Format, va_list _Args);__inline int __cdecl _sprintf_s_l(char *const _Buffer, size_t const _BufferCount, char const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vsprintf_s_l(_Buffer, _BufferCount, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1810 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl sprintf_s(char *const _Buffer, size_t const _BufferCount, char const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vsprintf_s_l(_Buffer, _BufferCount, _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1832 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" #line 1834 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _sprintf_p_l(char *const _Buffer, size_t const _BufferCount, char const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vsprintf_p_l(_Buffer, _BufferCount, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1862 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _sprintf_p(char *const _Buffer, size_t const _BufferCount, char const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vsprintf_p_l(_Buffer, _BufferCount, _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1882 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __declspec(deprecated("This function or variable may be unsafe. Consider using " "_snprintf_s_l" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl _snprintf_l(char *const _Buffer, size_t const _BufferCount, char const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vsnprintf_l(_Buffer, _BufferCount, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1905 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl snprintf(char *const _Buffer, size_t const _BufferCount, char const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=vsnprintf(_Buffer, _BufferCount, _Format, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1936 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _snprintf(char *const _Buffer, size_t const _BufferCount, char const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vsnprintf(_Buffer, _BufferCount, _Format, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1956 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __declspec(deprecated("This function or variable may be unsafe. Consider using " "_snprintf_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) int __cdecl _snprintf(char *_Buffer, size_t _BufferCount, char const *_Format,...);__declspec(deprecated("This function or variable may be unsafe. Consider using " "_vsnprintf_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) int __cdecl _vsnprintf(char *_Buffer, size_t _BufferCount, char const *_Format, va_list _Args);__inline int __cdecl _snprintf_c_l(char *const _Buffer, size_t const _BufferCount, char const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vsnprintf_c_l(_Buffer, _BufferCount, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 1986 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _snprintf_c(char *const _Buffer, size_t const _BufferCount, char const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vsnprintf_c_l(_Buffer, _BufferCount, _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 2006 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _snprintf_s_l(char *const _Buffer, size_t const _BufferCount, size_t const _MaxCount, char const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vsnprintf_s_l(_Buffer, _BufferCount, _MaxCount, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 2028 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _snprintf_s(char *const _Buffer, size_t const _BufferCount, size_t const _MaxCount, char const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vsnprintf_s_l(_Buffer, _BufferCount, _MaxCount, _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 2049 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _scprintf_l(char const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vscprintf_l(_Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 2075 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _scprintf(char const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vscprintf_l(_Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 2092 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _scprintf_p_l(char const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vscprintf_p_l(_Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 2110 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _scprintf_p(char const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vscprintf_p(_Format, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 2127 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" int __cdecl __stdio_common_vsscanf(unsigned __int64 _Options, char const *_Buffer, size_t _BufferCount, char const *_Format, _locale_t _Locale, va_list _ArgList);__inline int __cdecl _vsscanf_l(char const *const _Buffer, char const *const _Format, _locale_t const _Locale, va_list _ArgList) { return __stdio_common_vsscanf((*__local_stdio_scanf_options()), _Buffer,(size_t) -1, _Format, _Locale, _ArgList);} #line 2158 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl vsscanf(char const *const _Buffer, char const *const _Format, va_list _ArgList) { return _vsscanf_l(_Buffer, _Format,((void *) 0), _ArgList);} #line 2172 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _vsscanf_s_l(char const *const _Buffer, char const *const _Format, _locale_t const _Locale, va_list _ArgList) { return __stdio_common_vsscanf((*__local_stdio_scanf_options())|(1ULL<< 0), _Buffer,(size_t) -1, _Format, _Locale, _ArgList);} #line 2189 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" #pragma warning(push) #pragma warning(disable:6530) __inline int __cdecl vsscanf_s(char const *const _Buffer, char const *const _Format, va_list _ArgList) { return _vsscanf_s_l(_Buffer, _Format,((void *) 0), _ArgList);} #line 2208 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" #pragma warning(pop) #line 2219 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __declspec(deprecated("This function or variable may be unsafe. Consider using " "_sscanf_s_l" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl _sscanf_l(char const *const _Buffer, char const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vsscanf_l(_Buffer, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 2238 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __declspec(deprecated("This function or variable may be unsafe. Consider using " "sscanf_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl sscanf(char const *const _Buffer, char const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vsscanf_l(_Buffer, _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 2256 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _sscanf_s_l(char const *const _Buffer, char const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=_vsscanf_s_l(_Buffer, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 2275 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl sscanf_s(char const *const _Buffer, char const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=vsscanf_s(_Buffer, _Format, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 2297 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" #line 2299 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" #pragma warning(push) #pragma warning(disable:6530) __declspec(deprecated("This function or variable may be unsafe. Consider using " "_snscanf_s_l" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl _snscanf_l(char const *const _Buffer, size_t const _BufferCount, char const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=__stdio_common_vsscanf((*__local_stdio_scanf_options()), _Buffer, _BufferCount, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 2326 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __declspec(deprecated("This function or variable may be unsafe. Consider using " "_snscanf_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) __inline int __cdecl _snscanf(char const *const _Buffer, size_t const _BufferCount, char const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=__stdio_common_vsscanf((*__local_stdio_scanf_options()), _Buffer, _BufferCount, _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 2349 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _snscanf_s_l(char const *const _Buffer, size_t const _BufferCount, char const *const _Format, _locale_t const _Locale,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Locale))+((sizeof(_Locale)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=__stdio_common_vsscanf((*__local_stdio_scanf_options())|(1ULL<< 0), _Buffer, _BufferCount, _Format, _Locale, _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 2374 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" __inline int __cdecl _snscanf_s(char const *const _Buffer, size_t const _BufferCount, char const *const _Format,...) { int _Result;va_list _ArgList;((void)(_ArgList=(va_list)(&(_Format))+((sizeof(_Format)+sizeof(int) - 1) &~(sizeof(int) - 1)))) ;_Result=__stdio_common_vsscanf((*__local_stdio_scanf_options())|(1ULL<< 0), _Buffer, _BufferCount, _Format,((void *) 0), _ArgList);((void)(_ArgList=(va_list) 0)) ;return _Result;} #line 2397 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h" #pragma warning(pop) __declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_tempnam" ". See online help for details.")) char *__cdecl tempnam(char const *_Directory, char const *_FilePrefix);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_fcloseall" ". See online help for details.")) int __cdecl fcloseall(void);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_fdopen" ". See online help for details.")) FILE *__cdecl fdopen(int _FileHandle, char const *_Format);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_fgetchar" ". See online help for details.")) int __cdecl fgetchar(void);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_fileno" ". See online help for details.")) int __cdecl fileno(FILE *_Stream);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_flushall" ". See online help for details.")) int __cdecl flushall(void);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_fputchar" ". See online help for details.")) int __cdecl fputchar(int _Ch);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_getw" ". See online help for details.")) int __cdecl getw(FILE *_Stream);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_putw" ". See online help for details.")) int __cdecl putw(int _Ch, FILE *_Stream);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_rmtmp" ". See online help for details.")) int __cdecl rmtmp(void);#line 2441 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\stdio.h"__pragma(pack(pop))#pragma warning(pop) #pragma once#pragma once#pragma once#pragma once#pragma warning(push)#pragma warning(disable:4324 4514 4574 4710 4793 4820 4995 4996 28719 28726 28727) __pragma(pack(push, 8)) int *__cdecl _errno(void);errno_t __cdecl _set_errno(int _Value);errno_t __cdecl _get_errno(int *_Value);unsigned long *__cdecl __doserrno(void);errno_t __cdecl _set_doserrno(unsigned long _Value);errno_t __cdecl _get_doserrno(unsigned long *_Value);__pragma(pack(pop))#pragma warning(pop) #pragma once#pragma warning(push)#pragma warning(disable:4514 4820) __pragma(pack(push, 8)) void *__cdecl memchr(void const *_Buf, int _Val, size_t _MaxCount);int __cdecl memcmp(void const *_Buf1, void const *_Buf2, size_t _Size);void *__cdecl memcpy(void *_Dst, void const *_Src, size_t _Size);void *__cdecl memmove(void *_Dst, void const *_Src, size_t _Size);void *__cdecl memset(void *_Dst, int _Val, size_t _Size);char *__cdecl strchr(char const *_Str, int _Val);char *__cdecl strrchr(char const *_Str, int _Ch);char *__cdecl strstr(char const *_Str, char const *_SubStr);wchar_t *__cdecl wcschr(wchar_t const *_Str, wchar_t _Ch);wchar_t *__cdecl wcsrchr(wchar_t const *_Str, wchar_t _Ch);wchar_t *__cdecl wcsstr(wchar_t const *_Str, wchar_t const *_SubStr);__pragma(pack(pop))#pragma warning(pop) #pragma warning(push)#pragma warning(disable:4324 4514 4574 4710 4793 4820 4995 4996 28719 28726 28727) __pragma(pack(push, 8)) static __inline errno_t __cdecl memcpy_s(void *const _Destination, rsize_t const _DestinationSize, void const *const _Source, rsize_t const _SourceSize) { if(_SourceSize==0) { return 0;} { int _Expr_val=!!(_Destination !=((void *) 0));if(!(_Expr_val)) {(*_errno())=22;_invalid_parameter_noinfo();return 22;} } ;if(_Source==((void *) 0)||_DestinationSize< _SourceSize) { memset(_Destination, 0, _DestinationSize);{ int _Expr_val=!!(_Source !=((void *) 0));if(!(_Expr_val)) {(*_errno())=22;_invalid_parameter_noinfo();return 22;} } ;{ int _Expr_val=!!(_DestinationSize >=_SourceSize);if(!(_Expr_val)) {(*_errno())=34;_invalid_parameter_noinfo();return 34;} } ;return 22 ;} memcpy(_Destination, _Source, _SourceSize);return 0;} static __inline errno_t __cdecl memmove_s(void *const _Destination, rsize_t const _DestinationSize, void const *const _Source, rsize_t const _SourceSize) { if(_SourceSize==0) { return 0;} { int _Expr_val=!!(_Destination !=((void *) 0));if(!(_Expr_val)) {(*_errno())=22;_invalid_parameter_noinfo();return 22;} } ;{ int _Expr_val=!!(_Source !=((void *) 0));if(!(_Expr_val)) {(*_errno())=22;_invalid_parameter_noinfo();return 22;} } ;{ int _Expr_val=!!(_DestinationSize >=_SourceSize);if(!(_Expr_val)) {(*_errno())=34;_invalid_parameter_noinfo();return 34;} } ;memmove(_Destination, _Source, _SourceSize);return 0;}#pragma warning(pop) __pragma(pack(pop))#pragma warning(push)#pragma warning(disable:4324 4514 4574 4710 4793 4820 4995 4996 28719 28726 28727) __pragma(pack(push, 8)) int __cdecl _memicmp(void const *_Buf1, void const *_Buf2, size_t _Size);int __cdecl _memicmp_l(void const *_Buf1, void const *_Buf2, size_t _Size, _locale_t _Locale);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_memccpy" ". See online help for details.")) void *__cdecl memccpy(void *_Dst, void const *_Src, int _Val, size_t _Size);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_memicmp" ". See online help for details.")) int __cdecl memicmp(void const *_Buf1, void const *_Buf2, size_t _Size);__pragma(pack(pop))#pragma warning(pop) #pragma once#pragma warning(push)#pragma warning(disable:4324 4514 4574 4710 4793 4820 4995 4996 28719 28726 28727) __pragma(pack(push, 8)) errno_t __cdecl wcscat_s(wchar_t *_Destination, rsize_t _SizeInWords, wchar_t const *_Source);errno_t __cdecl wcscpy_s(wchar_t *_Destination, rsize_t _SizeInWords, wchar_t const *_Source);errno_t __cdecl wcsncat_s(wchar_t *_Destination, rsize_t _SizeInWords, wchar_t const *_Source, rsize_t _MaxCount);errno_t __cdecl wcsncpy_s(wchar_t *_Destination, rsize_t _SizeInWords, wchar_t const *_Source, rsize_t _MaxCount);wchar_t *__cdecl wcstok_s(wchar_t *_String, wchar_t const *_Delimiter, wchar_t **_Context);__declspec(allocator) wchar_t *__cdecl _wcsdup(wchar_t const *_String);__declspec(deprecated("This function or variable may be unsafe. Consider using " "wcscat_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) wchar_t *__cdecl wcscat(wchar_t *_Destination, wchar_t const *_Source);int __cdecl wcscmp(wchar_t const *_String1, wchar_t const *_String2);__declspec(deprecated("This function or variable may be unsafe. Consider using " "wcscpy_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) wchar_t *__cdecl wcscpy(wchar_t *_Destination, wchar_t const *_Source);size_t __cdecl wcscspn(wchar_t const *_String, wchar_t const *_Control);size_t __cdecl wcslen(wchar_t const *_String);size_t __cdecl wcsnlen(wchar_t const *_Source, size_t _MaxCount);static __inline size_t __cdecl wcsnlen_s(wchar_t const *_Source, size_t _MaxCount) { return(_Source==0) ? 0 :wcsnlen(_Source, _MaxCount);}__declspec(deprecated("This function or variable may be unsafe. Consider using " "wcsncat_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) wchar_t *__cdecl wcsncat(wchar_t *_Destination, wchar_t const *_Source, size_t _Count);int __cdecl wcsncmp(wchar_t const *_String1, wchar_t const *_String2, size_t _MaxCount);__declspec(deprecated("This function or variable may be unsafe. Consider using " "wcsncpy_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) wchar_t *__cdecl wcsncpy(wchar_t *_Destination, wchar_t const *_Source, size_t _Count);wchar_t *__cdecl wcspbrk(wchar_t const *_String, wchar_t const *_Control);size_t __cdecl wcsspn(wchar_t const *_String, wchar_t const *_Control);__declspec(deprecated("This function or variable may be unsafe. Consider using " "wcstok_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) wchar_t *__cdecl wcstok(wchar_t *_String, wchar_t const *_Delimiter, wchar_t **_Context);#line 237 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\corecrt_wstring.h" __declspec(deprecated("This function or variable may be unsafe. Consider using " "wcstok_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) static __inline wchar_t *__cdecl _wcstok(wchar_t *const _String, wchar_t const *const _Delimiter) { return wcstok(_String, _Delimiter, 0);} __declspec(deprecated("This function or variable may be unsafe. Consider using " "_wcserror_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) wchar_t *__cdecl _wcserror(int _ErrorNumber);errno_t __cdecl _wcserror_s(wchar_t *_Buffer, size_t _SizeInWords, int _ErrorNumber);__declspec(deprecated("This function or variable may be unsafe. Consider using " "__wcserror_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) wchar_t *__cdecl __wcserror(wchar_t const *_String);errno_t __cdecl __wcserror_s(wchar_t *_Buffer, size_t _SizeInWords, wchar_t const *_ErrorMessage);int __cdecl _wcsicmp(wchar_t const *_String1, wchar_t const *_String2);int __cdecl _wcsicmp_l(wchar_t const *_String1, wchar_t const *_String2, _locale_t _Locale);int __cdecl _wcsnicmp(wchar_t const *_String1, wchar_t const *_String2, size_t _MaxCount);int __cdecl _wcsnicmp_l(wchar_t const *_String1, wchar_t const *_String2, size_t _MaxCount, _locale_t _Locale);errno_t __cdecl _wcsnset_s(wchar_t *_Destination, size_t _SizeInWords, wchar_t _Value, size_t _MaxCount);__declspec(deprecated("This function or variable may be unsafe. Consider using " "_wcsnset_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) wchar_t *__cdecl _wcsnset(wchar_t *_String, wchar_t _Value, size_t _MaxCount);wchar_t *__cdecl _wcsrev(wchar_t *_String);errno_t __cdecl _wcsset_s(wchar_t *_Destination, size_t _SizeInWords, wchar_t _Value);__declspec(deprecated("This function or variable may be unsafe. Consider using " "_wcsset_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) wchar_t *__cdecl _wcsset(wchar_t *_String, wchar_t _Value);errno_t __cdecl _wcslwr_s(wchar_t *_String, size_t _SizeInWords);__declspec(deprecated("This function or variable may be unsafe. Consider using " "_wcslwr_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) wchar_t *__cdecl _wcslwr(wchar_t *_String);errno_t __cdecl _wcslwr_s_l(wchar_t *_String, size_t _SizeInWords, _locale_t _Locale);__declspec(deprecated("This function or variable may be unsafe. Consider using " "_wcslwr_s_l" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) wchar_t *__cdecl _wcslwr_l(wchar_t *_String, _locale_t _Locale);errno_t __cdecl _wcsupr_s(wchar_t *_String, size_t _Size);__declspec(deprecated("This function or variable may be unsafe. Consider using " "_wcsupr_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) wchar_t *__cdecl _wcsupr(wchar_t *_String);errno_t __cdecl _wcsupr_s_l(wchar_t *_String, size_t _Size, _locale_t _Locale);__declspec(deprecated("This function or variable may be unsafe. Consider using " "_wcsupr_s_l" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) wchar_t *__cdecl _wcsupr_l(wchar_t *_String, _locale_t _Locale);size_t __cdecl wcsxfrm(wchar_t *_Destination, wchar_t const *_Source, size_t _MaxCount);size_t __cdecl _wcsxfrm_l(wchar_t *_Destination, wchar_t const *_Source, size_t _MaxCount, _locale_t _Locale);int __cdecl wcscoll(wchar_t const *_String1, wchar_t const *_String2);int __cdecl _wcscoll_l(wchar_t const *_String1, wchar_t const *_String2, _locale_t _Locale);int __cdecl _wcsicoll(wchar_t const *_String1, wchar_t const *_String2);int __cdecl _wcsicoll_l(wchar_t const *_String1, wchar_t const *_String2, _locale_t _Locale);int __cdecl _wcsncoll(wchar_t const *_String1, wchar_t const *_String2, size_t _MaxCount);int __cdecl _wcsncoll_l(wchar_t const *_String1, wchar_t const *_String2, size_t _MaxCount, _locale_t _Locale);int __cdecl _wcsnicoll(wchar_t const *_String1, wchar_t const *_String2, size_t _MaxCount);int __cdecl _wcsnicoll_l(wchar_t const *_String1, wchar_t const *_String2, size_t _MaxCount, _locale_t _Locale);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_wcsdup" ". See online help for details.")) wchar_t *__cdecl wcsdup(wchar_t const *_String);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_wcsicmp" ". See online help for details.")) int __cdecl wcsicmp(wchar_t const *_String1, wchar_t const *_String2);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_wcsnicmp" ". See online help for details.")) int __cdecl wcsnicmp(wchar_t const *_String1, wchar_t const *_String2, size_t _MaxCount);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_wcsnset" ". See online help for details.")) wchar_t *__cdecl wcsnset(wchar_t *_String, wchar_t _Value, size_t _MaxCount);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_wcsrev" ". See online help for details.")) wchar_t *__cdecl wcsrev(wchar_t *_String);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_wcsset" ". See online help for details.")) wchar_t *__cdecl wcsset(wchar_t *_String, wchar_t _Value);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_wcslwr" ". See online help for details.")) wchar_t *__cdecl wcslwr(wchar_t *_String);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_wcsupr" ". See online help for details.")) wchar_t *__cdecl wcsupr(wchar_t *_String);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_wcsicoll" ". See online help for details.")) int __cdecl wcsicoll(wchar_t const *_String1, wchar_t const *_String2);__pragma(pack(pop))#pragma warning(pop) #pragma warning(push)#pragma warning(disable:4324 4514 4574 4710 4793 4820 4995 4996 28719 28726 28727) __pragma(pack(push, 8)) errno_t __cdecl strcpy_s(char *_Destination, rsize_t _SizeInBytes, char const *_Source);errno_t __cdecl strcat_s(char *_Destination, rsize_t _SizeInBytes, char const *_Source);errno_t __cdecl strerror_s(char *_Buffer, size_t _SizeInBytes, int _ErrorNumber);errno_t __cdecl strncat_s(char *_Destination, rsize_t _SizeInBytes, char const *_Source, rsize_t _MaxCount);errno_t __cdecl strncpy_s(char *_Destination, rsize_t _SizeInBytes, char const *_Source, rsize_t _MaxCount);char *__cdecl strtok_s(char *_String, char const *_Delimiter, char **_Context);void *__cdecl _memccpy(void *_Dst, void const *_Src, int _Val, size_t _MaxCount);__declspec(deprecated("This function or variable may be unsafe. Consider using " "strcat_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) char *__cdecl strcat(char *_Destination, char const *_Source);int __cdecl strcmp(char const *_Str1, char const *_Str2);int __cdecl _strcmpi(char const *_String1, char const *_String2);int __cdecl strcoll(char const *_String1, char const *_String2);int __cdecl _strcoll_l(char const *_String1, char const *_String2, _locale_t _Locale);__declspec(deprecated("This function or variable may be unsafe. Consider using " "strcpy_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) char *__cdecl strcpy(char *_Destination, char const *_Source);size_t __cdecl strcspn(char const *_Str, char const *_Control);__declspec(allocator) char *__cdecl _strdup(char const *_Source);__declspec(deprecated("This function or variable may be unsafe. Consider using " "_strerror_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) char *__cdecl _strerror(char const *_ErrorMessage);errno_t __cdecl _strerror_s(char *_Buffer, size_t _SizeInBytes, char const *_ErrorMessage);__declspec(deprecated("This function or variable may be unsafe. Consider using " "strerror_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) char *__cdecl strerror(int _ErrorMessage);int __cdecl _stricmp(char const *_String1, char const *_String2);int __cdecl _stricoll(char const *_String1, char const *_String2);int __cdecl _stricoll_l(char const *_String1, char const *_String2, _locale_t _Locale);int __cdecl _stricmp_l(char const *_String1, char const *_String2, _locale_t _Locale);size_t __cdecl strlen(char const *_Str);errno_t __cdecl _strlwr_s(char *_String, size_t _Size);__declspec(deprecated("This function or variable may be unsafe. Consider using " "_strlwr_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) char *__cdecl _strlwr(char *_String);errno_t __cdecl _strlwr_s_l(char *_String, size_t _Size, _locale_t _Locale);__declspec(deprecated("This function or variable may be unsafe. Consider using " "_strlwr_s_l" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) char *__cdecl _strlwr_l(char *_String, _locale_t _Locale);__declspec(deprecated("This function or variable may be unsafe. Consider using " "strncat_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) char *__cdecl strncat(char *_Destination, char const *_Source, size_t _Count);int __cdecl strncmp(char const *_Str1, char const *_Str2, size_t _MaxCount);int __cdecl _strnicmp(char const *_String1, char const *_String2, size_t _MaxCount);int __cdecl _strnicmp_l(char const *_String1, char const *_String2, size_t _MaxCount, _locale_t _Locale);int __cdecl _strnicoll(char const *_String1, char const *_String2, size_t _MaxCount);int __cdecl _strnicoll_l(char const *_String1, char const *_String2, size_t _MaxCount, _locale_t _Locale);int __cdecl _strncoll(char const *_String1, char const *_String2, size_t _MaxCount);int __cdecl _strncoll_l(char const *_String1, char const *_String2, size_t _MaxCount, _locale_t _Locale);size_t __cdecl __strncnt(char const *_String, size_t _Count);__declspec(deprecated("This function or variable may be unsafe. Consider using " "strncpy_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) char *__cdecl strncpy(char *_Destination, char const *_Source, size_t _Count);size_t __cdecl strnlen(char const *_String, size_t _MaxCount);static __inline size_t __cdecl strnlen_s(char const *_String, size_t _MaxCount) { return _String==0 ? 0 :strnlen(_String, _MaxCount);} errno_t __cdecl _strnset_s(char *_String, size_t _SizeInBytes, int _Value, size_t _MaxCount);__declspec(deprecated("This function or variable may be unsafe. Consider using " "_strnset_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) char *__cdecl _strnset(char *_Destination, int _Value, size_t _Count);char *__cdecl strpbrk(char const *_Str, char const *_Control);char *__cdecl _strrev(char *_Str);errno_t __cdecl _strset_s(char *_Destination, size_t _DestinationSize, int _Value);__declspec(deprecated("This function or variable may be unsafe. Consider using " "_strset_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) char *__cdecl _strset(char *_Destination, int _Value);size_t __cdecl strspn(char const *_Str, char const *_Control);__declspec(deprecated("This function or variable may be unsafe. Consider using " "strtok_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) char *__cdecl strtok(char *_String, char const *_Delimiter);errno_t __cdecl _strupr_s(char *_String, size_t _Size);__declspec(deprecated("This function or variable may be unsafe. Consider using " "_strupr_s" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) char *__cdecl _strupr(char *_String);errno_t __cdecl _strupr_s_l(char *_String, size_t _Size, _locale_t _Locale);__declspec(deprecated("This function or variable may be unsafe. Consider using " "_strupr_s_l" " instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. " "See online help for details.")) char *__cdecl _strupr_l(char *_String, _locale_t _Locale);size_t __cdecl strxfrm(char *_Destination, char const *_Source, size_t _MaxCount);size_t __cdecl _strxfrm_l(char *_Destination, char const *_Source, size_t _MaxCount, _locale_t _Locale);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_strdup" ". See online help for details.")) char *__cdecl strdup(char const *_String);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_strcmpi" ". See online help for details.")) int __cdecl strcmpi(char const *_String1, char const *_String2);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_stricmp" ". See online help for details.")) int __cdecl stricmp(char const *_String1, char const *_String2);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_strlwr" ". See online help for details.")) char *__cdecl strlwr(char *_String);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_strnicmp" ". See online help for details.")) int __cdecl strnicmp(char const *_String1, char const *_String2, size_t _MaxCount);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_strnset" ". See online help for details.")) char *__cdecl strnset(char *_String, int _Value, size_t _MaxCount);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_strrev" ". See online help for details.")) char *__cdecl strrev(char *_String);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_strset" ". See online help for details.")) char *__cdecl strset(char *_String, int _Value);__declspec(deprecated("The POSIX name for this item is deprecated. Instead, use the ISO C " "and C++ conformant name: " "_strupr" ". See online help for details.")) char *__cdecl strupr(char *_String);__pragma(pack(pop))#pragma warning(pop) #pragma once#pragma warning(push)#pragma warning(disable:4514 4820) __pragma(pack(push, 8)) __pragma(pack(pop))#pragma warning(pop) #pragma once#pragma warning(push)#pragma warning(disable:4324 4514 4574 4710 4793 4820 4995 4996 28719 28726 28727) typedef unsigned short _ino_t;typedef _ino_t ino_t;#line 24 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\sys/types.h" typedef unsigned int _dev_t;typedef _dev_t dev_t;#line 36 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\sys/types.h" typedef long _off_t;typedef _off_t off_t;#line 48 "C:/Program Files (x86)/Windows Kits/10/include/10.0.19041.0/ucrt\\sys/types.h"#pragma warning(pop) typedef char *sds;#pragma pack(push, 1) struct sdshdr5 { unsigned char flags;char buf[];};struct sdshdr8 { uint8_t len;uint8_t alloc;unsigned char flags;char buf[];};struct sdshdr16 { uint16_t len;uint16_t alloc;unsigned char flags;char buf[];};struct sdshdr32 { uint32_t len;uint32_t alloc;unsigned char flags;char buf[];};struct sdshdr64 { uint64_t len;uint64_t alloc;unsigned char flags;char buf[];};#pragma pack(pop) static inline size_t sdslen(const sds s) { unsigned char flags=s[-1];switch(flags &7) { case 0 :return((flags) >> 3) ;case 1 :return((struct sdshdr8 *)((s) -(sizeof(struct sdshdr8)))) ->len;case 2 :return((struct sdshdr16 *)((s) -(sizeof(struct sdshdr16)))) ->len;case 3 :return((struct sdshdr32 *)((s) -(sizeof(struct sdshdr32)))) ->len;case 4 :return((struct sdshdr64 *)((s) -(sizeof(struct sdshdr64)))) ->len;} return 0;}static inline size_t sdsavail(const sds s) { unsigned char flags=s[-1];switch(flags &7) { case 0 :{ return 0;} case 1 :{ struct sdshdr8 *sh=(void *)((s) -(sizeof(struct sdshdr8)));;return sh->alloc - sh->len;} case 2 :{ struct sdshdr16 *sh=(void *)((s) -(sizeof(struct sdshdr16)));;return sh->alloc - sh->len;} case 3 :{ struct sdshdr32 *sh=(void *)((s) -(sizeof(struct sdshdr32)));;return sh->alloc - sh->len;} case 4 :{ struct sdshdr64 *sh=(void *)((s) -(sizeof(struct sdshdr64)));;return sh->alloc - sh->len;} } return 0;}static inline void sdssetlen(sds s, size_t newlen) { unsigned char flags=s[-1];switch(flags &7) { case 0 :{ unsigned char *fp=((unsigned char *) s) - 1;*fp=0|(newlen<< 3);} break;case 1 :((struct sdshdr8 *)((s) -(sizeof(struct sdshdr8)))) ->len=(uint8_t) newlen;break;case 2 :((struct sdshdr16 *)((s) -(sizeof(struct sdshdr16)))) ->len=(uint16_t) newlen;break;case 3 :((struct sdshdr32 *)((s) -(sizeof(struct sdshdr32)))) -> len
Definition: CPAL.d:15583
int nglyphs
Definition: afm2pl.c:208
#define type(a)
Definition: aptex-macros.h:171
#define name
#define Font
#define POS_GT(pos1, pos2)
Definition: cff.cc:337
#define static_assert(c, msg)
Definition: cff.cc:31
CIDFont(Cff *cff, PermString, const Dict &, ErrorHandler *)
Definition: cff.cc:1466
Cff::Charset _charset
Definition: cff.hh:283
void font_matrix(double[6]) const
Definition: cff.cc:1546
PermString glyph_name(int) const
Definition: cff.cc:1564
IndexIterator _charstrings_index
Definition: cff.hh:285
Charstring * glyph(int) const
Definition: cff.cc:1581
int glyphid(PermString) const
Definition: cff.cc:1591
Cff::FDSelect _fdselect
Definition: cff.hh:289
Vector< Charstring * > _charstrings_cs
Definition: cff.hh:286
void glyph_names(Vector< PermString > &) const
Definition: cff.cc:1573
Vector< ChildFont * > _child_fonts
Definition: cff.hh:288
const CharstringProgram * child_program(int) const
Definition: cff.cc:1554
void assign(const Cff *, int pos, int nglyphs, int max_sid, ErrorHandler *=0)
Definition: cff.cc:586
int parse(const Cff *, int pos, int nglyphs, int max_sid, ErrorHandler *)
Definition: cff.cc:624
int error() const
Definition: cff.hh:179
int nglyphs() const
Definition: cff.hh:181
ChildFont(Cff *cff, Cff::CIDFont *, int charstring_type, const Dict &, ErrorHandler *=0)
Definition: cff.cc:1613
double global_width_x(bool) const
Definition: cff.cc:1680
double _nominal_width_x
Definition: cff.hh:332
int subr_bias() const
Definition: cff.cc:1674
IndexIterator _subrs_index
Definition: cff.hh:328
Charstring * charstring(const IndexIterator &, int) const
Definition: cff.cc:1649
Charstring * subr(int) const
Definition: cff.cc:1663
Vector< Charstring * > _subrs_cs
Definition: cff.hh:329
double _default_width_x
Definition: cff.hh:331
bool has(DictOperator) const
Definition: cff.cc:1084
int error() const
Definition: cff.hh:147
int check(bool is_private, ErrorHandler *=0, const char *dict_name="DICT") const
Definition: cff.cc:985
bool ok() const
Definition: cff.hh:146
bool xvalue(DictOperator, Vector< double > &) const
Definition: cff.cc:1093
bool value(DictOperator, Vector< double > &) const
Definition: cff.cc:1128
int assign(Cff *, int pos, int dict_len, ErrorHandler *=0, const char *dict_name="DICT")
Definition: cff.cc:838
bool has_first(DictOperator) const
Definition: cff.hh:440
void unparse(ErrorHandler *, const char *) const
Definition: cff.cc:1146
int parse(const Cff *, int pos, int nglyphs, ErrorHandler *)
Definition: cff.cc:708
void assign(const Cff *, int pos, int nglyphs, ErrorHandler *=0)
Definition: cff.cc:689
int error() const
Definition: cff.hh:204
Charstring * charstring(const IndexIterator &, int) const
Definition: cff.cc:1205
FontParent(Cff *cff)
Definition: cff.cc:1199
Charstring * gsubr(int) const
Definition: cff.cc:1219
int gsubr_bias() const
Definition: cff.cc:1225
void glyph_names(Vector< PermString > &) const
Definition: cff.cc:1388
Cff::Charset _charset
Definition: cff.hh:371
Font(Cff *cff, PermString, const Dict &, ErrorHandler *)
Definition: cff.cc:1235
int glyphid(PermString) const
Definition: cff.cc:1417
Charstring * glyph(int) const
Definition: cff.cc:1396
Vector< Charstring * > _charstrings_cs
Definition: cff.hh:374
bool dict_has(DictOperator) const
Definition: cff.cc:1445
int assign_standard_encoding(const int *standard_encoding)
Definition: cff.cc:1359
PermString glyph_name(int) const
Definition: cff.cc:1379
IndexIterator _charstrings_index
Definition: cff.hh:373
int parse_encoding(int pos, ErrorHandler *)
Definition: cff.cc:1279
void font_matrix(double[6]) const
Definition: cff.cc:1367
String dict_string(DictOperator) const
Definition: cff.cc:1451
Type1Encoding * type1_encoding() const
Definition: cff.cc:1423
Type1Encoding * type1_encoding_copy() const
Definition: cff.cc:1433
const uint8_t * _contents
Definition: cff.hh:102
const uint8_t * _offset
Definition: cff.hh:103
const uint8_t * _last_offset
Definition: cff.hh:104
const uint8_t * index_end() const
Definition: cff.cc:804
uint32_t offset_at(const uint8_t *) const
Definition: cff.hh:388
int nitems() const
Definition: cff.cc:813
int error() const
Definition: cff.hh:84
Vector< FontParent * > _fonts
Definition: cff.hh:129
PermString font_name(int i) const
Definition: cff.hh:33
Cff(const String &str, unsigned units_per_em, ErrorHandler *errh=0)
Definition: cff.cc:340
Vector< Charstring * > _gsubrs_cs
Definition: cff.hh:128
const uint8_t * data() const
Definition: cff.hh:29
int _len
Definition: cff.hh:115
bool ok() const
Definition: cff.hh:25
@ tNone
Definition: cff.hh:70
@ tFontNumber
Definition: cff.hh:70
@ tNumber
Definition: cff.hh:70
@ tOffset
Definition: cff.hh:70
@ tArray3
Definition: cff.hh:71
@ tArray4
Definition: cff.hh:71
@ tBoolean
Definition: cff.hh:70
@ tArray2
Definition: cff.hh:71
@ tArray5
Definition: cff.hh:71
@ tPrivate
Definition: cff.hh:72
@ tLocalOffset
Definition: cff.hh:70
@ tPrivateType
Definition: cff.hh:71
@ tArray6
Definition: cff.hh:71
@ tSID
Definition: cff.hh:70
@ tArray
Definition: cff.hh:71
@ tTypeMask
Definition: cff.hh:72
int sid(PermString)
Definition: cff.cc:425
String sid_string(int sid) const
Definition: cff.cc:458
int ngsubrs() const
Definition: cff.hh:42
Vector< PermString > _strings
Definition: cff.hh:124
int _error
Definition: cff.hh:117
static const int operator_types[]
Definition: cff.hh:76
int max_sid() const
Definition: cff.hh:37
int parse_header(ErrorHandler *)
Definition: cff.cc:366
static const char *const operator_names[]
Definition: cff.hh:75
@ NSTANDARD_STRINGS
Definition: cff.hh:36
@ MAX_SID
Definition: cff.hh:36
const String & data_string() const
Definition: cff.hh:28
int nfonts() const
Definition: cff.hh:32
PermString sid_permstring(int sid) const
Definition: cff.cc:476
Charstring * gsubr(int i)
Definition: cff.cc:558
Vector< PermString > _name_index
Definition: cff.hh:119
DictOperator
Definition: cff.hh:47
@ oCharset
Definition: cff.hh:51
@ oFontMatrix
Definition: cff.hh:56
@ oFDSelect
Definition: cff.hh:65
@ oROS
Definition: cff.hh:63
@ oCharStrings
Definition: cff.hh:52
@ oSubrs
Definition: cff.hh:52
@ oLastOperator
Definition: cff.hh:66
@ oCharstringType
Definition: cff.hh:56
@ oEncoding
Definition: cff.hh:51
@ oFDArray
Definition: cff.hh:65
@ oDefaultWidthX
Definition: cff.hh:52
@ oNominalWidthX
Definition: cff.hh:53
@ oPrivate
Definition: cff.hh:52
HashMap< PermString, int > _strings_map
Definition: cff.hh:125
unsigned units_per_em() const
Definition: cff.hh:45
@ HEADER_SIZE
Definition: cff.hh:135
~Cff()
Definition: cff.cc:353
FontParent * font(PermString=PermString(), ErrorHandler *=0)
Definition: cff.cc:500
IndexIterator _strings_index
Definition: cff.hh:123
IndexIterator _gsubrs_index
Definition: cff.hh:127
IndexIterator _top_dict_index
Definition: cff.hh:121
const uint8_t * _data
Definition: cff.hh:114
void set_parent_program(bool pp)
Definition: t1cs.hh:211
static Type1Encoding * standard_encoding()
Definition: t1item.cc:615
Error reporting class.
Definition: error.hh:86
int error(const char *fmt,...)
Print an error message (level el_error).
Definition: error.cc:818
int nerrors() const
Return the number of errors reported via this handler.
Definition: error.hh:282
int warning(const char *fmt,...)
Print a warning message (level el_warning).
Definition: error.cc:808
static ErrorHandler * silent_handler()
Return the global silent ErrorHandler.
Definition: error.hh:167
void message(const char *fmt,...)
Print an informational message (level el_info).
Definition: error.cc:799
static ErrorHandler * default_handler()
Return the default ErrorHandler.
Definition: error.hh:155
const char * c_str() const
Definition: permstr.hh:41
Efficiently build up Strings from pieces.
Definition: straccum.hh:21
const char * c_str()
Null-terminate this StringAccum and return its data.
Definition: straccum.cc:122
void pop_back(int n=1)
Remove characters from the end of the StringAccum.
Definition: straccum.hh:444
void clear()
Clear the StringAccum's comments.
Definition: straccum.hh:371
Definition: vector.hh:17
Vector< T > & assign(size_type n, const T &e=T())
Definition: vector.cc:65
void resize(size_type nn, const T &e=T())
Definition: vector.cc:166
size_type size() const
Definition: vector.hh:54
#define n
Definition: t4ht.c:1290
void invalid(int opcode)
Definition: disdvi.c:818
struct rect data
Definition: dvipdfm.c:64
char * digit
Definition: io.c:63
Flexible error handling classes.
#define s
Definition: afcover.h:80
#define d(n)
Definition: gpos-common.c:151
#define memcmp(s1, s2, n)
Definition: gsftopk.c:66
#define memcpy(d, s, n)
Definition: gsftopk.c:64
FILE * out
Definition: hbf2gf.c:286
#define slen
Definition: hpcdtoppm.c:1329
assert(pcxLoadImage24((char *)((void *) 0), fp, pinfo, hdr))
char String
Definition: tttypes.h:35
small capitals from c petite p
Definition: afcover.h:72
small capitals from c petite p scientific i
Definition: afcover.h:80
FT_Vector * vec
Definition: ftbbox.c:469
FT_UInt sid
Definition: cffcmap.c:138
CFF_Font cff
Definition: cffdrivr.c:701
#define const
Definition: ftzconf.h:91
signed short int16_t
Definition: stdint.h:76
unsigned int uint32_t
Definition: stdint.h:80
signed int int32_t
Definition: stdint.h:77
unsigned char uint8_t
Definition: stdint.h:78
int num
Definition: disdvi.c:621
#define buf
@ parse
Definition: spc_dvips.c:737
#define floor(x)
Definition: cpascal.h:52
#define length(c)
Definition: ctangleboot.c:65
#define isdigit(c)
Definition: snprintf.c:177
const int * pos
Definition: combiners.h:905
static PermString standard_permstrings[Cff::NSTANDARD_STRINGS]
Definition: cff.cc:150
static const int expert_charset[]
Definition: cff.cc:243
static const int expert_encoding[]
Definition: cff.cc:184
static const int iso_adobe_charset[]
Definition: cff.cc:215
static int subr_bias(int charstring_type, int nsubrs)
Definition: cff.cc:545
static const int standard_encoding[]
Definition: cff.cc:153
static PermString::Initializer initializer
Definition: cff.cc:78
static int handle_private(Cff *cff, const Cff::Dict &top_dict, Cff::Dict &private_dict, double &default_width_x, double &nominal_width_x, Cff::IndexIterator &subrs_index, Vector< Charstring * > &subrs_cs, ErrorHandler *errh)
Definition: cff.cc:1170
static const char *const standard_strings[]
Definition: cff.cc:79
static HashMap< PermString, int > standard_permstrings_map(-1)
static char xvalue[256]
Definition: afmparse.cc:33
static const uint8_t default_dict_cff_data[]
Definition: cff.cc:279
static const Cff::Dict & default_dict()
Definition: cff.cc:330
static const int expert_subset_charset[]
Definition: cff.cc:265
dictionary off
Definition: fc-lang.py:226
static int format
Definition: pbmclean.c:15
PermString permprintf(const char *format,...)
Definition: permstr.cc:298
float ** matrix()
struct const_name font_name[]
Definition: picttoppm.c:492
#define fp
@ tNumber
static int32_t first
Definition: ppagelist.c:29
static int size
Definition: ppmlabel.c:24
int g
Definition: ppmqvga.c:68
bstring c int memset(void *s, int c, int length)
charset
Definition: charset.h:51
static ErrorHandler * errh
Definition: main.cc:71
#define parent(a, t)
Definition: interp.c:105
d0
Definition: sec_div.c:122
d1
Definition: sec_div.c:81
ShellFileEnvironment e
Definition: sh6.c:388
Click's StringAccum class, used to construct Strings efficiently from pieces.
A string of characters.
Definition: t1part.c:49
String substring(const char *begin, const char *end) const
Return a substring of the current string starting at begin and ending before end.
Definition: string.hh:371
static String make_stable(const char *s, int len=-1)
Return a String that directly references the first len characters of s.
Definition: string.cc:263
Definition: pst1form.c:310
Definition: sh.h:1226
Definition: strexpr.c:21
int j
Definition: t4ht.c:1589
s1
Definition: t4ht.c:1059
found
Definition: tex4ht.c:5000
op
Definition: tex4ht.c:3129
return() int(((double) *(font_tbl[cur_fnt].wtbl+(int)(*(font_tbl[cur_fnt].char_wi+(int)(ch - font_tbl[cur_fnt].char_f)% 256)))/(double)(1L<< 20)) *(double) font_tbl[cur_fnt].scale)