You absolutely should not have to do that. If you do then it is a reportable and serious bug. strcpy() is utterly documented as setting the terminating null.
> memset(Jobn,'0',sizeof(Jobn)); Assume you mean memset(Jobn,'\0',sizeof(Jobn)); Charles -----Original Message----- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Scott Ford Sent: Tuesday, September 04, 2012 12:04 PM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Strings (hijacked from: The IBM zEnterprise EC12 announcment) I have had to move a string type field like a parameter to a field like this, Jobn char[40]; memset(Jobn,'0',sizeof(Jobn)); strcpy(Jobn,xxxxx); Otherwise strcmp fails, where xxxxx is the parameter string ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN