diff options
author | root <root@fedora-arm.domain.avtechpulse.com> | 2012-08-01 10:56:49 -0400 |
---|---|---|
committer | root <root@fedora-arm.domain.avtechpulse.com> | 2012-08-01 10:56:49 -0400 |
commit | ef779d4e445b7c92fceb61cce35730720407d46e (patch) | |
tree | 7110b125a4124cd287bcd8882c286929041d999a /response.c | |
parent | 34d2cb9de274e9b65709250c80ff25d3d8635099 (diff) |
strip off whitespace from the input, in the response generator
Diffstat (limited to 'response.c')
-rw-r--r-- | response.c | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -106,8 +106,11 @@ void responseCb(gpointer instance, GObject *arg1, gpointer user_data) gssize len = data->size; gssize written = 0; - gchar* upper = g_ascii_strup(str, len); + // remove leading and trailing whitespace + g_strstrip (str); + // dummy response function + gchar* upper = g_ascii_strup(str, len); gchar *out_string = g_strdup_printf("%s\n%s\n%s\n",upper,upper,upper); gssize out_len = strlen (out_string); |