strcat(缓冲区,\\\\ n); //在此操作之后 //字符串是LF终止,没有 // nul strcpy (Buffer, "MAIL FROM: "); m_From.GetWindowText(Text, 512); // sorry if this is MFC strcat (Buffer, Text); // up to this point the string is nul // terminated // Buffer is passed to a function but is still null // terminated following the call strcat(Buffer, "\r\n"); // after this operation the // string is LF terminated with no // nul 什么是strlen(缓冲区)与sizeof (缓冲区)?What is strlen(Buffer) vs. sizeof(Buffer)? 这篇关于strcat - 奇怪的行为的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 上岸,阿里云!
08-15 11:42