aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Christian Hesse <mail@eworm.de>2013-05-30 21:00:27 +0200
committerGravatar Christian Hesse <mail@eworm.de>2013-05-30 21:00:27 +0200
commit9f32b22f154f8757e200159eaf2b7cbb76284a73 (patch)
tree15faf6877e618e74163fdd4dc34d43f70c07c5d8
parent6d72684048fb0d1e70fdb8a48b9062eb4b713d18 (diff)
downloadcqrlogo-9f32b22f154f8757e200159eaf2b7cbb76284a73.tar.gz
cqrlogo-9f32b22f154f8757e200159eaf2b7cbb76284a73.tar.zst
match protocol case insensitive
-rw-r--r--cqrlogo.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/cqrlogo.c b/cqrlogo.c
index 45c006d..dd78211 100644
--- a/cqrlogo.c
+++ b/cqrlogo.c
@@ -75,8 +75,8 @@ int main(int argc, char **argv) {
}
/* prepare pattern matching */
- pattern = malloc(10 + strlen(server_name));
- sprintf(pattern, "^http://%s/", server_name);
+ pattern = malloc(22 + strlen(server_name));
+ sprintf(pattern, "^[hH][tT][tT][pP]://%s/", server_name);
if ((rc = regcomp(&preg, pattern, 0)) != 0)
fprintf(stderr, "regcomp() failed, returning nonzero (%d)\n", rc);