]> git.pond.sub.org Git - empserver/commitdiff
[_WIN32] (loc_StripDels): Remove. Different behavior depending on the
authorMarkus Armbruster <armbru@pond.sub.org>
Sat, 11 Jun 2005 16:44:01 +0000 (16:44 +0000)
committerMarkus Armbruster <armbru@pond.sub.org>
Sat, 11 Jun 2005 16:44:01 +0000 (16:44 +0000)
platform is evil, and line editing is none of the server's business
anyway.  If your client can't deal with the delete key, well, here's a
nickel, kid, get yourself a better computer.

src/lib/gen/ioqueue.c

index 41f68cda1beb409f6dde484e7edb2ad2e44e2ab2..472a855635537d483ffbfb57cbe7fa888d146fff 100644 (file)
@@ -169,9 +169,6 @@ ioq_gets(struct ioqueue *ioq, s_char *buf, int cc)
        buf[actual] = '\0';
        /* remove the newline too */
        removecc(ioq, nbytes + 1);
-#if defined(_WIN32)
-       loc_StripDels(buf);
-#endif
     }
     return nbytes;
 }
@@ -420,34 +417,3 @@ ioq_makebuf(struct ioqueue *ioq, char *pBuf, int nBufLen)
     return ncopied;
 }
 #endif /* _WIN32 */
-
-#if defined(_WIN32)
-/*
- * Remove backspaces and DELs from the buffer.
- *
- * Why?  Because I got tired of telneting into the
- * server and having to type perfectly...
- */
-static void
-loc_StripDels(char *pBuf)
-{
-    char *cp;
-    char *dp;
-    char *sp;
-
-    for (cp = pBuf; *cp;) {
-       /* Remove Backspace and DEL */
-       if (*cp == '\b' || *cp == '\x8F') {
-           if (cp == pBuf)
-               dp = cp;
-           else
-               dp = cp - 1;
-           sp = cp + 1;
-           while (*sp)
-               *dp++ = *sp++;
-           *dp = 0;
-       } else
-           cp++;
-    }
-}
-#endif