Contents 1 Definitions 2 Character encodings 3 Overview of functions 3.1 Constants and types 3.2 Functions 3.2.1 Multibyte functions 3.3 Numeric conversions 4 Popular extensions 5 Replacements 6 See also 7 Notes 8 References 9 External links


Definitions[edit] A string is a contiguous sequence of code units terminated by the first zero code (\0, corresponding to the null character). In C, there are two types of strings: string, which is sometimes called byte string which uses the type char as code units (one char is at least 8 bits), and wide string[1] which uses the type wchar_t as code units. A common misconception is that all char arrays are strings, because string literals are converted to arrays during the compilation (or translation) phase.[2] It is important to remember that a string ends at the first zero code unit. An array or string literal that contains a zero before the last byte therefore contains a string, or possibly several strings, but is not itself a string.[3] Conversely, it is possible to create a char array that is not null-terminated and is thus not a string: char is often used as a small integer when needing to save memory. The term pointer to a string is used in C to describe a pointer to the initial (lowest-addressed) byte of a string.[1] In C, pointers are used to pass strings to functions. Documentation (including this page) will often use the term string to mean pointer to a string.[citation needed] The term length of a string is used in C to describe the number of bytes preceding the zero byte.[1] strlen is a standardised function commonly used to determine the length of a string. A common mistake is to not realize that a string uses one more unit of memory than this length, in order to store the zero that ends the string.


Character encodings[edit] This section needs additional citations for verification. Please help improve this article by adding citations to reliable sources. Unsourced material may be challenged and removed. (January 2017) (Learn how and when to remove this template message) Each string ends at the first occurrence of the zero code unit of the appropriate kind (char or wchar_t). Consequently, a byte string can contain non-NUL characters in ASCII or any ASCII extension, but not characters in encodings such as UTF-16 (even though a 16-bit code unit might be nonzero, its high or low byte might be zero). The encodings that can be stored in wide strings are defined by the width of wchar_t. In most implementations, wchar_t is at least 16 bits, and so all 16-bit encodings, such as UCS-2, can be stored. If wchar_t is 32-bits, then 32-bit encodings, such as UTF-32, can be stored. Variable-width encodings can be used in both byte strings and wide strings. String length and offsets are measured in bytes or wchar_t, not in "characters", which can be confusing to beginning programmers. UTF-8 and Shift JIS are often used in C byte strings, while UTF-16 is often used in C wide strings when wchar_t is 16 bits. Truncating strings with variable length characters using functions like strncpy can produce invalid sequences at the end of the string. This can be unsafe if the truncated parts are interpreted by code that assumes the input is valid. Support for Unicode literals such as char foo[512] = "φωωβαρ";(UTF-8) or wchar_t foo[512] = L"φωωβαρ"; (UTF-16 or UTF-32) is implementation defined,[4] and may require that the source code be in the same encoding. Some compilers or editors will require entering all non-ASCII characters as \xNN sequences for each byte of UTF-8, and/or \uNNNN for each word of UTF-16.


Overview of functions[edit] Most of the functions that operate on C strings are declared in the string.h header (cstring in C++), while functions that operate on C wide strings are declared in the wchar.h header (cwchar in C++). These headers also contain declarations of functions used for handling memory buffers; the name is thus something of a misnomer. Functions declared in string.h are extremely popular since, as a part of the C standard library, they are guaranteed to work on any platform which supports C. However, some security issues exist with these functions, such as potential buffer overflows when not used carefully and properly, causing the programmers to prefer safer and possibly less portable variants, out of which some popular ones are listed below. Some of these functions also violate const-correctness by accepting a const string pointer and returning a non-const pointer within the string. To correct this, some have been separated into two overloaded functions in the C++ version of the standard library. In historical documentation the term "character" was often used instead of "byte" for C strings, which leads many[who?] to believe that these functions somehow do not work for UTF-8. In fact all lengths are defined as being in bytes and this is true in all implementations, and these functions work as well with UTF-8 as with single-byte encodings. The BSD documentation has been fixed to make this clear, but POSIX, Linux, and Windows documentation still uses "character" in many places where "byte" or "wchar_t" is the correct term. Functions for handling memory buffers can process sequences of bytes that include null-byte as part of the data. Names of these functions typically start with mem, as opposite to the str prefix. Constants and types[edit] Name Notes NULL Macro expanding to the null pointer constant; that is, a constant representing a pointer value which is guaranteed not to be a valid address of an object in memory. wchar_t Type used for a code unit in wide strings, usually an unsigned 16 bit or 32 bit value. No specific interpretation is specified for these code units; the C standard only requires that wchar_t be wide enough to hold the widest character set among the supported system locales.[5] Theoretically, wchar_t can be the same size as char, and thus not capable of holding UTF-32 or UTF-16 code units.[6] wint_t Integer type that can hold any value of a wchar_t as well as the value of the macro WEOF. This type is unchanged by integral promotions. Usually a 32 bit signed value. mbstate_t Contains all the information about the conversion state required from one call to a function to the other. Functions[edit] Byte string Wide string Description[note 1] String manipulation strcpy[7] wcscpy[8] Copies one string to another strncpy[9] wcsncpy[10] Writes exactly n bytes, copying from source or adding nulls strcat[11] wcscat[12] Appends one string to another strncat[13] wcsncat[14] Appends no more than n bytes from one string to another strxfrm[15] wcsxfrm[16] Transforms a string according to the current locale String examination strlen[17] wcslen[18] Returns the length of the string strcmp[19] wcscmp[20] Compares two strings (three-way comparison) strncmp[21] wcsncmp[22] Compares a specific number of bytes in two strings strcoll[23] wcscoll[24] Compares two strings according to the current locale strchr[25] wcschr[26] Finds the first occurrence of a byte in a string strrchr[27] wcsrchr[28] Finds the last occurrence of a byte in a string strspn[29] wcsspn[30] Returns the number of initial bytes in a string that are in a second string strcspn[31] wcscspn[32] Returns the number of initial bytes in a string that are not in a second string strpbrk[33] wcspbrk[34] Finds in a string the first occurrence of a byte in a set strstr[35] wcsstr[36] Finds the first occurrence of a substring in a string strtok[37] wcstok[38] Splits a string into tokens Miscellaneous strerror[39] N/A Returns a string containing a message derived from an error code Memory manipulation memset[40] wmemset[41] Fills a buffer with a repeated byte memcpy[42] wmemcpy[43] Copies one buffer to another memmove[44] wmemmove[45] Copies one buffer to another, possibly overlapping, buffer memcmp[46] wmemcmp[47] Compares two buffers (three-way comparison) memchr[48] wmemchr[49] Finds the first occurrence of a byte in a buffer ^ For wide string functions substitute wchar_t for "byte" in the description Multibyte functions[edit] Name Description mblen[50] Returns the number of bytes in the next multibyte character mbtowc[51] Converts the next multibyte character to a wide character wctomb[52] Converts a wide character to its multibyte representation mbstowcs[53] Converts a multibyte string to a wide string wcstombs[54] Converts a wide string to a multibyte string btowc[55] Convert a single-byte character to wide character, if possible wctob[56] Convert a wide character to a single-byte character, if possible mbsinit[57] Checks if a state object represents initial state mbrlen[58] Returns the number of bytes in the next multibyte character, given state mbrtowc[59] Converts the next multibyte character to a wide character, given state wcrtomb[60] Converts a wide character to its multibyte representation, given state mbsrtowcs[61] Converts a multibyte string to a wide string, given state wcsrtombs[62] Converts a wide string to a multibyte string, given state These functions all take a pointer to a mbstate_t object that the caller must maintain. This was originally intended to track shift states in the mb encodings, but modern ones such as UTF-8 do not need this. However these functions were designed on the assumption that the wc encoding is not a variable-width encoding and thus are designed to deal with exactly one wchar_t at a time, passing it by value rather than using a string pointer. As UTF-16 is a variable-width encoding, the mbstate_t has been reused to keep track of surrogate pairs in the wide encoding, though the caller must still detect and call mbtowc twice for a single character.[63][64][65] Numeric conversions[edit] Byte string Wide string Description[note 1] atof[66] N/A converts a string to a floating-point value atoi atol atoll[67] N/A converts a string to an integer (C99) strtof (C99)[68] strtod[69] strtold (C99)[70] wcstof (C99)[71] wcstod[72] wcstold (C99)[73] converts a string to a floating-point value strtol strtoll[74] wcstol wcstoll[75] converts a string to a signed integer strtoul strtoull[76] wcstoul wcstoull[77] converts a string to an unsigned integer ^ Here string refers either to byte string or wide string The C standard library contains several functions for numeric conversions. The functions that deal with byte strings are defined in the stdlib.h header (cstdlib header in C++). The functions that deal with wide strings are defined in the wchar.h header (cwchar header in C++). The strtoxxx functions are not const-correct, since they accept a const string pointer and return a non-const pointer within the string. Also, since the Normative Amendment 1 (C95), atoxx functions are considered subsumed by strtoxxx functions, for which reason neither C95 nor any later standard provides wide-character versions of these functions.[78]


Popular extensions[edit] Name Platform Description bzero[79][80] POSIX, BSD Fills a buffer with zero bytes, deprecated by memset memccpy[81] SVID, POSIX copies up to specified number of bytes between two memory areas, which must not overlap, stopping when a given byte is found. mempcpy[82] GNU a variant of memcpy returning a pointer to the byte following the last written byte strcasecmp[83] POSIX, BSD case-insensitive versions of strcmp strcat_s[84] Windows a variant of strcat that checks the destination buffer size before copying strcpy_s[85] Windows a variant of strcpy that checks the destination buffer size before copying strdup[86] POSIX allocates and duplicates a string strerror_r[87] POSIX 1, GNU a variant of strerror that is thread-safe. The GNU version is incompatible with the POSIX one. stricmp[88] Windows case-insensitive versions of strcmp strlcpy[89] BSD, Solaris a variant of strcpy that truncates the result to fit in the destination buffer[90] strlcat[89] BSD, Solaris a variant of strcat that truncates the result to fit in the destination buffer[90] strsignal[91] POSIX:2008 returns string representation of a signal code. Not thread safe. strtok_r[92] POSIX a variant of strtok that is thread-safe


Replacements[edit] Despite the well-established need to replace strcat[11] and strcpy[7] with functions that do not allow buffer overflows, no accepted standard has arisen. This is partly due to the mistaken belief by many C programmers that strncat and strncpy have the desired behavior; however, neither function was designed for this (they were intended to manipulate null-padded fixed-size string buffers, a data format less commonly used in modern software), and the behavior and arguments are non-intuitive and often written incorrectly even by expert programmers.[90] The most popular[a] replacement are the strlcat and strlcpy functions, which appeared in OpenBSD 2.4 in December, 1998.[90] These functions always write one NUL to the destination buffer, truncating the result if necessary, and return the size of buffer that would be needed, which allows detection of the truncation and provides a size for creating a new buffer that will not truncate. They have been criticized on the basis of allegedly being inefficient[93] and encouraging the use of C strings (instead of some superior alternative form of string).[94][95] Consequently, they have not been included in the GNU C library (used by software on Linux), although they are implemented in the C libraries for OpenBSD, FreeBSD, NetBSD, Solaris, OS X, and QNX, as well as in alternative C libraries for Linux, such as musl.[96][97] The lack of GNU C library support has not stopped various software authors from using it and bundling a replacement, among other SDL, GLib, ffmpeg, rsync, and even internally in the Linux kernel. Open source implementations for these functions are available.[98][99] As part of its 2004 Security Development Lifecycle, Microsoft introduced a family of "secure" functions including strcpy_s and strcat_s (along with many others).[100] These functions were standardized with some minor changes as part of the optional C11 (Annex K) proposed by ISO/IEC WDTR 24731. Experience with these functions has shown significant problems with their adoption and errors in usage, so the removal of Annex K is proposed for the next revision of the C standard.[101] These functions perform various checks including whether the string is too long to fit in the buffer. If the checks fail, a user-specified "runtime-constraint handler" function is called,[102] which usually aborts the program.[103][104] Some functions perform destructive operations before calling the runtime-constraint handler; for example, strcat_s sets the destination to the empty string,[105] which can make it difficult to recover from error conditions or debug them. These functions attracted considerable criticism because initially they were implemented only on Windows and at the same time warning messages started to be produced by Microsoft Visual C++ suggesting the programmers to use these functions instead of standard ones. This has been speculated by some to be an attempt by Microsoft to lock developers into its platform.[106] Although open-source implementations of these functions are available,[107] these functions are not present in common Unix C libraries. If the string length is known, then memcpy[42] or memmove[44] can be more efficient than strcpy[citation needed], so some programs[who?] use them to optimize C string manipulation. They accept a buffer length as a parameter, so they can be employed to prevent buffer overflows in a manner similar to the aforementioned functions.


See also[edit] C syntax § Strings – source code syntax, including backslash escape sequences String functions


Notes[edit] ^ On GitHub, there are 7,813,206 uses of strlcpy, versus 38,644 uses of strcpy_s (and 15,286,150 uses of strcpy).[citation needed]


References[edit] ^ a b c "The C99 standard draft + TC3" (PDF). §7.1.1p1. Retrieved 7 January 2011.  ^ "The C99 standard draft + TC3" (PDF). §6.4.5p7. Retrieved 7 January 2011.  ^ "The C99 standard draft + TC3" (PDF). Section 6.4.5 footnote 66. Retrieved 7 January 2011.  ^ "The C99 standard draft + TC3" (PDF). §5.1.1.2 Translation phases, p1. Retrieved 23 December 2011.  ^ "stddef.h - standard type definitions". The Open Group. Retrieved 2017-01-28.  ^ Gillam, Richard (2003). Unicode Demystified: A Practical Programmer's Guide to the Encoding Standard. Addison-Wesley Professional. p. 714.  ^ a b "strcpy - cppreference.com". En.cppreference.com. 2014-01-02. Retrieved 2014-03-06.  ^ "wcscpy - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "strncpy - cppreference.com". En.cppreference.com. 2013-10-04. Retrieved 2014-03-06.  ^ "wcsncpy - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ a b "strcat - cppreference.com". En.cppreference.com. 2013-10-08. Retrieved 2014-03-06.  ^ "wcscat - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "strncat - cppreference.com". En.cppreference.com. 2013-07-01. Retrieved 2014-03-06.  ^ "wcsncat - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "strxfrm - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "wcsxfrm - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "strlen - cppreference.com". En.cppreference.com. 2013-12-27. Retrieved 2014-03-06.  ^ "wcslen - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "strcmp - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "wcscmp - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "strncmp - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "wcsncmp - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "strcoll - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "wcscoll - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "strchr - cppreference.com". En.cppreference.com. 2014-02-23. Retrieved 2014-03-06.  ^ "wcschr - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "strrchr - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "wcsrchr - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "strspn - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "wcsspn - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "strcspn - cppreference.com". En.cppreference.com. 2013-05-31. Retrieved 2014-03-06.  ^ "wcscspn - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "strpbrk - cppreference.com". En.cppreference.com. 2013-05-31. Retrieved 2014-03-06.  ^ "wcspbrk - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "strstr - cppreference.com". En.cppreference.com. 2013-10-16. Retrieved 2014-03-06.  ^ "wcsstr - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "strtok - cppreference.com". En.cppreference.com. 2013-09-03. Retrieved 2014-03-06.  ^ "wcstok - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "strerror - cppreference.com". En.cppreference.com. 2013-05-31. Retrieved 2014-03-06.  ^ "memset - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "wmemset - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ a b "memcpy - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "wmemcpy - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ a b "memmove - cppreference.com". En.cppreference.com. 2014-01-25. Retrieved 2014-03-06.  ^ "wmemmove - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "memcmp - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "wmemcmp - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "memchr - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "wmemchr - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "mblen - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "mbtowc - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "wctomb - cppreference.com". En.cppreference.com. 2014-02-04. Retrieved 2014-03-06.  ^ "mbstowcs - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "wcstombs - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "btowc - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "wctob - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "mbsinit - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "mbrlen - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "mbrtowc - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "wcrtomb - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "mbsrtowcs - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "wcsrtombs - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "6.3.2 Representing the state of the conversion". "The GNU C Library". Retrieved 2017-01-31.  ^ "root/src/multibyte/c16rtomb.c". Retrieved 2017-01-31.  ^ "Contents of /stable/11/lib/libc/locale/c16rtomb.c". Retrieved 2017-01-31.  ^ "atof - cppreference.com". En.cppreference.com. 2013-05-31. Retrieved 2014-03-06.  ^ "atoi, atol, atoll - cppreference.com". En.cppreference.com. 2014-01-18. Retrieved 2014-03-06.  ^ "strtof, strtod, strtold - cppreference.com". En.cppreference.com. 2014-02-04. Retrieved 2014-03-06.  ^ "strtof, strtod, strtold - cppreference.com". En.cppreference.com. 2014-02-04. Retrieved 2014-03-06.  ^ "strtof, strtod, strtold - cppreference.com". En.cppreference.com. 2014-02-04. Retrieved 2014-03-06.  ^ "wcstof, wcstod, wcstold - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "wcstof, wcstod, wcstold - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "wcstof, wcstod, wcstold - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "strtol, strtoll - cppreference.com". En.cppreference.com. 2014-02-04. Retrieved 2014-03-06.  ^ "wcstol, wcstoll - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ "strtoul, strtoull - cppreference.com". En.cppreference.com. 2014-02-04. Retrieved 2014-03-06.  ^ "wcstoul, wcstoull - cppreference.com". En.cppreference.com. Retrieved 2014-03-06.  ^ C99 Rationale, 7.20.1.1 ^ "bzero". The Open Group. Retrieved 2017-11-27.  ^ "bzero(3)". OpenBSD. Retrieved 2017-11-27.  ^ "memccpy". Pubs.opengroup.org. Retrieved 2014-03-06.  ^ "mempcpy(3) - Linux manual page". Kernel.org. Retrieved 2014-03-06.  ^ "strcasecmp(3) - Linux manual page". Kernel.org. Retrieved 2014-03-06.  ^ "strcat_s, wcscat_s, _mbscat_s". Msdn.microsoft.com. Retrieved 2014-03-06.  ^ "strcpy_s, wcscpy_s, _mbscpy_s". Msdn.microsoft.com. Retrieved 2014-03-06.  ^ "strdup". Pubs.opengroup.org. Retrieved 2014-03-06.  ^ "strerror(3) - Linux manual page". Kernel.org. Retrieved 2014-03-06.  ^ "String | stricmp()". C Programming Expert.com. Retrieved 2014-03-06.  ^ a b "strlcpy, strlcat — size-bounded string copying and concatenation". OpenBSD. Retrieved 2016-05-26.  ^ a b c d Todd C. Miller; Theo de Raadt (1999). "strlcpy and strlcat – consistent, safe, string copy and concatenation". USENIX '99.  ^ "strsignal". Pubs.opengroup.org. Retrieved 2014-03-06.  ^ "strtok". Pubs.opengroup.org. Retrieved 2014-03-06.  ^ Miller, Damien (October 2005). "Secure Portability" (PDF). Retrieved 26 June 2016. This [strlcpy and strlcat] API has been adopted by most modern operating systems and many standalone software packages [...]. The notable exception is the GNU standard C library, glibc, whose maintainer steadfastly refuses to include these improved APIs, labelling them “horribly inefficient BSD crap”, despite prior evidence that they are faster is most cases than the APIs they replace.  ^ libc-alpha mailing list, selected messages from 8 August 2000 thread: 53, 60, 61 ^ The ups and downs of strlcpy(); LWN.net ^ "root/src/string/strlcpy.c". Retrieved 2017-01-28.  ^ "root/src/string/strlcat.c". Retrieved 2017-01-28.  ^ Todd C. Miller. "strlcpy.c". BSD Cross Reference.  ^ Todd C. Miller. "strlcat.c". BSD Cross Reference.  ^ Lovell, Martyn. "Repel Attacks on Your Code with the Visual Studio 2005 Safe C and C++ Libraries". Retrieved 13 February 2015.  ^ "Field Experience With Annex K — Bounds Checking Interfaces". Retrieved 5 November 2015.  ^ "The C11 standard draft" (PDF). §K.3.1.4p2. Retrieved 13 February 2013.  ^ "The C11 standard draft" (PDF). §K.3.6.1.1p4. Retrieved 13 February 2013.  ^ "Parameter Validation".  ^ "The C11 standard draft" (PDF). §K.3.7.2.1p4. Retrieved 13 February 2013.  ^ Danny Kalev. "They're at it again". InformIT. Retrieved 10 November 2011.  ^ Safe C Library. "The Safe C Library provides bound checking memory and string functions per ISO/IEC TR24731". Sourceforge. Retrieved 6 March 2013. 


External links[edit] The Wikibook C Programming has a page on the topic of: C Programming/Strings Fast memcpy in C, multiple C coding examples to target different types of CPU instruction architectures v t e C programming language ANSI C C89 and C90 C99 C11 Embedded C MISRA C Features Functions Header files Libraries Operators String Syntax Preprocessor Data types Standard library functions Char (ctype.h) File I/O (stdio.h) Math (math.h) Dynamic memory (stdlib.h) String (string.h) Time (time.h) Variadic (stdarg.h) POSIX Standard libraries Bionic libhybris dietlibc EGLIBC glibc klibc Microsoft Run-time Library musl Newlib uClibc BSD libc Compilers Comparison of compilers ACK Borland Turbo C Clang GCC ICC LCC Pelles C PCC SDCC TCC Microsoft Visual Studio / Express / C++ Watcom C/C++ IDEs Comparison of IDEs Anjuta Code::Blocks CodeLite Eclipse Geany Microsoft Visual Studio NetBeans Comparison with other languages Compatibility of C and C++ Comparison with Embedded C Comparison with Pascal Comparison of programming languages Descendant languages C++ C# D Objective-C Alef Limbo Go Vala Category Retrieved from "https://en.wikipedia.org/w/index.php?title=C_string_handling&oldid=812801880" Categories: C (programming language)C standard libraryString (computer science)Hidden categories: All articles with unsourced statementsArticles with unsourced statements from February 2015Use dmy dates from January 2012Articles with unsourced statements from March 2013Articles needing additional references from January 2017All articles needing additional referencesAll articles with specifically marked weasel-worded phrasesArticles with specifically marked weasel-worded phrases from January 2017Articles with unsourced statements from December 2015Articles with specifically marked weasel-worded phrases from December 2015


Navigation menu Personal tools Not logged inTalkContributionsCreate accountLog in Namespaces ArticleTalk Variants Views ReadEditView history More Search Navigation Main pageContentsFeatured contentCurrent eventsRandom articleDonate to WikipediaWikipedia store Interaction HelpAbout WikipediaCommunity portalRecent changesContact page Tools What links hereRelated changesUpload fileSpecial pagesPermanent linkPage informationWikidata itemCite this page Print/export Create a bookDownload as PDFPrintable version Languages EspañolفارسیFrançais한국어ItalianoPortuguêsРусскийไทยУкраїнська中文 Edit links This page was last edited on 29 November 2017, at 23:21. Text is available under the Creative Commons Attribution-ShareAlike License; additional terms may apply. By using this site, you agree to the Terms of Use and Privacy Policy. Wikipedia® is a registered trademark of the Wikimedia Foundation, Inc., a non-profit organization. Privacy policy About Wikipedia Disclaimers Contact Wikipedia Developers Cookie statement Mobile view (window.RLQ=window.RLQ||[]).push(function(){mw.config.set({"wgPageParseReport":{"limitreport":{"cputime":"0.828","walltime":"0.923","ppvisitednodes":{"value":5377,"limit":1000000},"ppgeneratednodes":{"value":0,"limit":1500000},"postexpandincludesize":{"value":176308,"limit":2097152},"templateargumentsize":{"value":4213,"limit":2097152},"expansiondepth":{"value":14,"limit":40},"expensivefunctioncount":{"value":8,"limit":500},"entityaccesscount":{"value":0,"limit":400},"timingprofile":["100.00% 834.970 1 -total"," 57.31% 478.561 2 Template:Reflist"," 45.35% 378.632 103 Template:Cite_web"," 9.38% 78.344 5 Template:Fix"," 8.66% 72.345 81 Template:Anchor"," 7.42% 61.918 3 Template:Citation_needed"," 4.78% 39.929 8 Template:Category_handler"," 4.02% 33.594 5 Template:Delink"," 3.42% 28.544 1 Template:Redirect"," 2.36% 19.672 1 Template:Refimprove_section"]},"scribunto":{"limitreport-timeusage":{"value":"0.483","limit":"10.000"},"limitreport-memusage":{"value":6013715,"limit":52428800}},"cachereport":{"origin":"mw1263","timestamp":"20180219030727","ttl":1900800,"transientcontent":false}}});});(window.RLQ=window.RLQ||[]).push(function(){mw.config.set({"wgBackendResponseTime":88,"wgHostname":"mw1238"});});


C_string_handling - Photos and All Basic Informations

C_string_handling More Links

C String (disambiguation)C Standard LibraryC Data TypesC Character ClassificationC Mathematical FunctionsC File Input/outputC Date And Time FunctionsC Localization FunctionsC Dynamic Memory AllocationC Process ControlC Signal HandlingC Alternative TokensAssert.hErrno.hSetjmp.hStdarg.hTemplate:C Standard LibraryTemplate Talk:C Standard LibraryC (programming Language)String (computer Science)C Standard LibraryConcatenationTokenization (lexical Analysis)Null-terminated StringArray (data Structure)String LiteralCode UnitNull CharacterString LiteralWikipedia:Citation NeededWikipedia:VerifiabilityHelp:Introduction To Referencing With Wiki Markup/1Help:Maintenance Template RemovalNull CharacterASCIIExtended ASCIIUTF-16UCS-2UTF-32Variable-width EncodingUTF-8Shift JISUTF-16C Standard LibraryBuffer OverflowConst-correctnessFunction OverloadingWikipedia:Manual Of Style/Words To WatchUTF-8Null PointerC Localization FunctionsUTF-32UTF-16Three-way ComparisonErrno.hVariable-width EncodingC99C99C99C99C99Const-correctnessPOSIXBSDSystem V Interface DefinitionPOSIXSignal (computing)C Standard LibraryOpenBSDGNU C LibraryFreeBSDNetBSDSolaris (operating System)OS XQNXMuslSpecification And Description LanguageGLibFFmpegRsyncLinux KernelMicrosoft Security Development LifecycleC11 (C Standard Revision)Microsoft Visual C++Wikipedia:Citation NeededWikipedia:Manual Of Style/Words To WatchC SyntaxString FunctionsWikipedia:Citation NeededThe Open GroupOpenBSDOpenBSDTemplate:C Programming LanguageTemplate Talk:C Programming LanguageC (programming Language)ANSI CANSI CC99C11 (C Standard Revision)Embedded CMISRA CSubroutineInclude DirectiveCategory:C LibrariesOperators In C And C++C SyntaxC PreprocessorC Data TypesC Standard LibraryC Character ClassificationC File Input/outputC Mathematical FunctionsC Dynamic Memory AllocationC Date And Time FunctionsStdarg.hC POSIX LibraryCategory:C Standard LibraryBionic (software)Hybris (software)DietlibcEmbedded GLIBCGNU C LibraryKlibcMicrosoft Windows Library FilesMuslNewlibUClibcBSD LibcCategory:C CompilersList Of CompilersAmsterdam Compiler KitBorland Turbo CClangGNU Compiler CollectionIntel C++ CompilerLCC (compiler)Pelles CPortable C CompilerSmall Device C CompilerTiny C CompilerMicrosoft Visual StudioMicrosoft Visual Studio ExpressVisual C++Watcom C/C++Category:Integrated Development EnvironmentsComparison Of Integrated Development EnvironmentsAnjutaCode::BlocksCodeLiteEclipse (software)GeanyMicrosoft Visual StudioNetBeansCategory:Comparison Of Individual Programming LanguagesCompatibility Of C And C++Embedded CComparison Of Pascal And CComparison Of Programming LanguagesC++C Sharp (programming Language)D (programming Language)Objective-CAlef (programming Language)Limbo (programming Language)Go (programming Language)Vala (programming Language)Category:C (programming Language)Help:CategoryCategory:C (programming Language)Category:C Standard LibraryCategory:String (computer Science)Category:All Articles With Unsourced StatementsCategory:Articles With Unsourced Statements From February 2015Category:Use Dmy Dates From January 2012Category:Articles With Unsourced Statements From March 2013Category:Articles Needing Additional References From January 2017Category:All Articles Needing Additional ReferencesCategory:All Articles With Specifically Marked Weasel-worded PhrasesCategory:Articles With Specifically Marked Weasel-worded Phrases From January 2017Category:Articles With Unsourced Statements From December 2015Category:Articles With Specifically Marked Weasel-worded Phrases From December 2015Discussion About Edits From This IP Address [n]A List Of Edits Made From This IP Address [y]View The Content Page [c]Discussion About The Content Page [t]Edit This Page [e]Visit The Main Page [z]Guides To Browsing WikipediaFeatured Content – The Best Of WikipediaFind Background Information On Current EventsLoad A Random Article [x]Guidance On How To Use And Edit WikipediaFind Out About WikipediaAbout The Project, What You Can Do, Where To Find ThingsA List Of Recent Changes In The Wiki [r]List Of All English Wikipedia Pages Containing Links To This Page [j]Recent Changes In Pages Linked From This Page [k]Upload Files [u]A List Of All Special Pages [q]Wikipedia:AboutWikipedia:General Disclaimer



view link view link view link view link view link