Tools, game engines, and games can benefit from safe, fast handling of strings, and in this Gamasutra technical feature
, veteran game coder Joe Linhoff explains and makes available a new, low-level library to avoid issues created by standard C string functions.
As Linhoff explains in his introduction, many times these standard C functions may serve their intended function, but may come up short in terms of security or performance:
“Tools, game engines, and games can benefit from safe, fast string handling. Many string libraries are based on C's standard functions. While the standard C string functions are sometimes adequate, they are often unsafe, slow, or not suited to multi-threaded programming. Often, they thwart safe, clean, efficient problem solving.
Many high level string libraries build on C's standard approach and inherit these problems. This article presents a new, low-level library to address and overcome these issues. In addition, the code for the string library has also been made available here for download.”
You can now read the entire in-depth feature, which includes additional explanations, as well as code samples for developers to use to get around the shortcomings of using standard C string functions (no registration required, please feel free to link to this feature from external websites).