This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

c++/2142: silly internal error for a well placed ";"



>Number:         2142
>Category:       c++
>Synopsis:       silly internal error for a well placed ";"
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu Mar 01 14:46:00 PST 2001
>Closed-Date:
>Last-Modified:
>Originator:     mike andrews
>Release:        2.96
>Organization:
>Environment:
linux redhat
>Description:

>How-To-Repeat:
void escape(char *buf)
{
  // make sure we escape \, <, and >, work from end of buffer
  int l, offs=0;
  char c;
  
  l=strlen(buf);
  
  while ((c=buf[l])!='\0';) {
    if (c=='\\' || c=='<' || c=='>') {
      buf[l+offs]='\\'; offs++;
    }
    buf[l+offs]=c;
  }
}
>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]