← Commit list

0ad4daa54

Glenn L McGrath
Glenn L McGrath
2003-10-01
FAILED Duration: 85s

Subject

Patch from Rob Landley to fix backrefs

Binary

No binary (build failed)

Architecture & Compiler Flags

Architecture: x86_64-linux-gnu Compiler: gcc (Ubuntu 11.4.0-1ubuntu1~22.04.3) 11.4.0

—

Build Log

(log yok)

Commit Diff GitHub →

editors/sed.c+1 -1
@@ -570,7 +570,7 @@ static void do_subst_w_backrefs(const char *line, const char *replace)
/* go through the replacement string */
for (i = 0; replace[i]; i++) {
/* if we find a backreference (\1, \2, etc.) print the backref'ed * text */
- if (replace[i] == '\\' && replace[i+1]>0 && replace[i+1]<=9) {
+ if (replace[i] == '\\' && replace[i+1]>'0' && replace[i+1]<='9') {
int backref=replace[++i]-'0';
/* print out the text held in regmatch[backref] */