CVSTrac Legacy Code

Check-in [dab276db97]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:(#799) properly escape %%.
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:dab276db971d34fcecb83b7d94e4cef97257e57d
User & Date: ono 2009-05-14 12:25:21
Context
2009-05-15
12:32
*: Download tarball is now directory browse action, rather than separate link *: Tarball now contains version and subdirectory only if necessary *: Determines modification date using filechng table *: Subversion now fixed for UNIX environment, also supports pure =tar=, =tar.gz= and =tar.bz2= *: GIT implementation using =git archive= check-in: 8c8238f05e user: ono tags: trunk
2009-05-14
12:25
(#799) properly escape %%. check-in: dab276db97 user: ono tags: trunk
12:11
(#534, #567) ensure we are not sending Content-Length with value of 0 (zero), that may happen on some actions and confuse browsers. check-in: 73773e45d3 user: ono tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to ticket.c.

148
149
150
151
152
153
154

155
156
157
158

159
160
161
162
163
164
165
    azSubst[i] = quotable_string(azSubst[i]);
    cmdSize += cnt[i]*strlen(azSubst[i]);
  }

  zCmd = malloc( cmdSize + 1 );
  if( zCmd==0 ) return;
  for(i=j=0; zNotify[i]; i++){

    if( zNotify[i]=='%' && (c = zNotify[i+1]&0x7f)!=0 && azSubst[c]!=0 ){
      int k;
      const char *z = azSubst[c];
      for(k=0; z[k]; k++){ zCmd[j++] = z[k]; }

      i++;
    }else{
      zCmd[j++] = zNotify[i];
    }
  }
  zCmd[j] = 0;
  assert( j<=cmdSize );







>
|
|
|
|
>







148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
    azSubst[i] = quotable_string(azSubst[i]);
    cmdSize += cnt[i]*strlen(azSubst[i]);
  }

  zCmd = malloc( cmdSize + 1 );
  if( zCmd==0 ) return;
  for(i=j=0; zNotify[i]; i++){
    if( zNotify[i]=='%' && zNotify[i+1]!='%' ){
      if( (c = zNotify[i+1]&0x7f)!=0 && azSubst[c]!=0 ){
        int k;
        const char *z = azSubst[c];
        for(k=0; z[k]; k++){ zCmd[j++] = z[k]; }
      }
      i++;
    }else{
      zCmd[j++] = zNotify[i];
    }
  }
  zCmd[j] = 0;
  assert( j<=cmdSize );