sprintf is it safe to use?

1 Ansicht (letzte 30 Tage)
Daniel Martelli
Daniel Martelli am 3 Sep. 2020
Beantwortet: Bruno Luong am 3 Sep. 2020
Is it safe to use the code sprintf? because i was reading something and it said that sprintf is not safe to use
  4 Kommentare
KSSV
KSSV am 3 Sep. 2020
Share the link where there was a warning.
per isakson
per isakson am 3 Sep. 2020
"sprintf is not safe to use" in what programming language?

Melden Sie sich an, um zu kommentieren.

Akzeptierte Antwort

Bruno Luong
Bruno Luong am 3 Sep. 2020
It's not safe for C where strings are 0 terminated.
But for MATLAB the length is inside an internal (mxArray) structure, so it's totally safe.

Weitere Antworten (0)

Kategorien

Mehr zu Entering Commands finden Sie in Help Center und File Exchange

Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by