Commit 961445a
authored
Fix std.outbuffer.[v]printf() for Visual Studio 2015+
MS conforms to the standard beginning with VS 2015, i.e., if the buffer is too small,
vsnprintf() returns the number of required characters (excl. terminating null). VS 2013
and earlier always returned -1 in that case.
So just use the generic (previous POSIX) version, it's compatible with older VS anyway.
Already unittested in line 380 ("hello world 6" vs. "hello world 62665").1 parent 04e09c3 commit 961445a
1 file changed
+11
-32
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
256 | 256 | | |
257 | 257 | | |
258 | 258 | | |
259 | | - | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
260 | 264 | | |
261 | | - | |
262 | | - | |
263 | | - | |
264 | | - | |
265 | | - | |
266 | | - | |
267 | | - | |
268 | 265 | | |
269 | 266 | | |
270 | | - | |
271 | | - | |
272 | 267 | | |
273 | | - | |
| 268 | + | |
274 | 269 | | |
275 | | - | |
276 | | - | |
277 | | - | |
278 | | - | |
279 | | - | |
280 | | - | |
281 | | - | |
282 | | - | |
283 | | - | |
284 | | - | |
285 | | - | |
286 | | - | |
287 | | - | |
288 | | - | |
289 | | - | |
290 | | - | |
291 | | - | |
292 | | - | |
| 270 | + | |
| 271 | + | |
293 | 272 | | |
294 | 273 | | |
295 | | - | |
296 | | - | |
297 | | - | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
298 | 277 | | |
299 | 278 | | |
300 | 279 | | |
| |||
0 commit comments