tbeu / matio

MATLAB MAT File I/O Library
https://matio.sourceforge.io
BSD 2-Clause "Simplified" License
330 stars 97 forks source link

Replace various sprintf with snprintf #231

Closed seanm closed 4 months ago

seanm commented 5 months ago

snprintf is safer because the buffer length is specified, so can't be overrun.

seanm commented 5 months ago

@tbeu ah, I suppose this is to support old MS compilers, that did not support C99 properly?

tbeu commented 5 months ago

@tbeu ah, I suppose this is to support old MS compilers, that did not support C99 properly?

Exactly. AppVeyor (and my local VS setup) could not build your initial change.