Gitweb links:

...log 
http://git.netsurf-browser.org/netsurf.git/shortlog/fa5e6fcdf90907e238ea74edf4ffdba7656fb163
...commit 
http://git.netsurf-browser.org/netsurf.git/commit/fa5e6fcdf90907e238ea74edf4ffdba7656fb163
...tree 
http://git.netsurf-browser.org/netsurf.git/tree/fa5e6fcdf90907e238ea74edf4ffdba7656fb163

The branch, master has been updated
       via  fa5e6fcdf90907e238ea74edf4ffdba7656fb163 (commit)
       via  ca12878c2f0c1617a1b86a0c54b3a94b88c1caa6 (commit)
      from  9d858085c31a668aae89c696fef1a684c50cb8c6 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commitdiff 
http://git.netsurf-browser.org/netsurf.git/commit/?id=fa5e6fcdf90907e238ea74edf4ffdba7656fb163
commit fa5e6fcdf90907e238ea74edf4ffdba7656fb163
Author: Vincent Sanders <[email protected]>
Commit: Vincent Sanders <[email protected]>

    make html content line parsing use no locale dependant ascii processing

diff --git a/render/html.c b/render/html.c
index 96251ea..5a2aa4f 100644
--- a/render/html.c
+++ b/render/html.c
@@ -23,7 +23,6 @@
  */
 
 #include <assert.h>
-#include <ctype.h>
 #include <stdint.h>
 #include <string.h>
 #include <strings.h>
@@ -40,6 +39,7 @@
 #include "utils/utf8.h"
 #include "utils/nsoption.h"
 #include "utils/string.h"
+#include "utils/ascii.h"
 #include "netsurf/content.h"
 #include "netsurf/browser_window.h"
 #include "netsurf/utf8.h"
@@ -394,7 +394,7 @@ static nserror 
html_meta_refresh_process_element(html_content *c, dom_node *n)
        url = dom_string_data(content);
 
        /* *LWS */
-       while (url < end && isspace(*url)) {
+       while (url < end && ascii_is_space(*url)) {
                url++;
        }
 
@@ -422,7 +422,7 @@ static nserror 
html_meta_refresh_process_element(html_content *c, dom_node *n)
        }
 
        /* *LWS */
-       while (url < end && isspace(*url)) {
+       while (url < end && ascii_is_space(*url)) {
                url++;
        }
 
@@ -431,7 +431,7 @@ static nserror 
html_meta_refresh_process_element(html_content *c, dom_node *n)
                url++;
 
        /* *LWS */
-       while (url < end && isspace(*url)) {
+       while (url < end && ascii_is_space(*url)) {
                url++;
        }
 
@@ -463,7 +463,7 @@ static nserror 
html_meta_refresh_process_element(html_content *c, dom_node *n)
        }
 
        /* *LWS */
-       while (url < end && isspace(*url)) {
+       while (url < end && ascii_is_space(*url)) {
                url++;
        }
 
@@ -483,7 +483,7 @@ static nserror 
html_meta_refresh_process_element(html_content *c, dom_node *n)
        }
 
        /* *LWS */
-       while (url < end && isspace(*url)) {
+       while (url < end && ascii_is_space(*url)) {
                url++;
        }
 
@@ -502,7 +502,7 @@ static nserror 
html_meta_refresh_process_element(html_content *c, dom_node *n)
                        url++;
        } else {
                /* url-nq */
-               while (url < end && !isspace(*url))
+               while (url < end && !ascii_is_space(*url))
                        url++;
        }
 


commitdiff 
http://git.netsurf-browser.org/netsurf.git/commit/?id=ca12878c2f0c1617a1b86a0c54b3a94b88c1caa6
commit ca12878c2f0c1617a1b86a0c54b3a94b88c1caa6
Author: Vincent Sanders <[email protected]>
Commit: Vincent Sanders <[email protected]>

    use ascii processing when determining form charset

diff --git a/render/form.c b/render/form.c
index 8ae59b5..52e54e4 100644
--- a/render/form.c
+++ b/render/form.c
@@ -26,7 +26,6 @@
  */
 
 #include <assert.h>
-#include <ctype.h>
 #include <limits.h>
 #include <stdbool.h>
 #include <stdio.h>
@@ -40,6 +39,7 @@
 #include "utils/url.h"
 #include "utils/utf8.h"
 #include "utils/utils.h"
+#include "utils/ascii.h"
 #include "content/fetch.h"
 #include "content/hlcache.h"
 #include "css/utils.h"
@@ -980,8 +980,9 @@ char *form_acceptable_charset(struct form *form)
                return NULL;
 
        /* make it upper case */
-       for (c = temp; *c; c++)
-               *c = toupper(*c);
+       for (c = temp; *c; c++) {
+               *c = ascii_to_upper(*c);
+       }
 
        /* is UTF-8 specified? */
        c = strstr(temp, "UTF-8");
@@ -997,14 +998,14 @@ char *form_acceptable_charset(struct form *form)
         * form element contains a space and/or comma separated list */
        c = form->accept_charsets;
 
-       /* What would be an improvement would be to choose an encoding
+       /** \todo an improvement would be to choose an encoding
         * acceptable to the server which covers as much of the input
-        * values as possible. Additionally, we need to handle the case
-        * where none of the acceptable encodings cover all the textual
-        * input values.
-        * For now, we just extract the first element of the charset list
+        * values as possible. Additionally, we need to handle the
+        * case where none of the acceptable encodings cover all the
+        * textual input values.  For now, we just extract the first
+        * element of the charset list
         */
-       while (*c && !isspace(*c)) {
+       while (*c && !ascii_is_space(*c)) {
                if (*c == ',')
                        break;
                c++;


-----------------------------------------------------------------------

Summary of changes:
 render/form.c |   19 ++++++++++---------
 render/html.c |   14 +++++++-------
 2 files changed, 17 insertions(+), 16 deletions(-)

diff --git a/render/form.c b/render/form.c
index 8ae59b5..52e54e4 100644
--- a/render/form.c
+++ b/render/form.c
@@ -26,7 +26,6 @@
  */
 
 #include <assert.h>
-#include <ctype.h>
 #include <limits.h>
 #include <stdbool.h>
 #include <stdio.h>
@@ -40,6 +39,7 @@
 #include "utils/url.h"
 #include "utils/utf8.h"
 #include "utils/utils.h"
+#include "utils/ascii.h"
 #include "content/fetch.h"
 #include "content/hlcache.h"
 #include "css/utils.h"
@@ -980,8 +980,9 @@ char *form_acceptable_charset(struct form *form)
                return NULL;
 
        /* make it upper case */
-       for (c = temp; *c; c++)
-               *c = toupper(*c);
+       for (c = temp; *c; c++) {
+               *c = ascii_to_upper(*c);
+       }
 
        /* is UTF-8 specified? */
        c = strstr(temp, "UTF-8");
@@ -997,14 +998,14 @@ char *form_acceptable_charset(struct form *form)
         * form element contains a space and/or comma separated list */
        c = form->accept_charsets;
 
-       /* What would be an improvement would be to choose an encoding
+       /** \todo an improvement would be to choose an encoding
         * acceptable to the server which covers as much of the input
-        * values as possible. Additionally, we need to handle the case
-        * where none of the acceptable encodings cover all the textual
-        * input values.
-        * For now, we just extract the first element of the charset list
+        * values as possible. Additionally, we need to handle the
+        * case where none of the acceptable encodings cover all the
+        * textual input values.  For now, we just extract the first
+        * element of the charset list
         */
-       while (*c && !isspace(*c)) {
+       while (*c && !ascii_is_space(*c)) {
                if (*c == ',')
                        break;
                c++;
diff --git a/render/html.c b/render/html.c
index 96251ea..5a2aa4f 100644
--- a/render/html.c
+++ b/render/html.c
@@ -23,7 +23,6 @@
  */
 
 #include <assert.h>
-#include <ctype.h>
 #include <stdint.h>
 #include <string.h>
 #include <strings.h>
@@ -40,6 +39,7 @@
 #include "utils/utf8.h"
 #include "utils/nsoption.h"
 #include "utils/string.h"
+#include "utils/ascii.h"
 #include "netsurf/content.h"
 #include "netsurf/browser_window.h"
 #include "netsurf/utf8.h"
@@ -394,7 +394,7 @@ static nserror 
html_meta_refresh_process_element(html_content *c, dom_node *n)
        url = dom_string_data(content);
 
        /* *LWS */
-       while (url < end && isspace(*url)) {
+       while (url < end && ascii_is_space(*url)) {
                url++;
        }
 
@@ -422,7 +422,7 @@ static nserror 
html_meta_refresh_process_element(html_content *c, dom_node *n)
        }
 
        /* *LWS */
-       while (url < end && isspace(*url)) {
+       while (url < end && ascii_is_space(*url)) {
                url++;
        }
 
@@ -431,7 +431,7 @@ static nserror 
html_meta_refresh_process_element(html_content *c, dom_node *n)
                url++;
 
        /* *LWS */
-       while (url < end && isspace(*url)) {
+       while (url < end && ascii_is_space(*url)) {
                url++;
        }
 
@@ -463,7 +463,7 @@ static nserror 
html_meta_refresh_process_element(html_content *c, dom_node *n)
        }
 
        /* *LWS */
-       while (url < end && isspace(*url)) {
+       while (url < end && ascii_is_space(*url)) {
                url++;
        }
 
@@ -483,7 +483,7 @@ static nserror 
html_meta_refresh_process_element(html_content *c, dom_node *n)
        }
 
        /* *LWS */
-       while (url < end && isspace(*url)) {
+       while (url < end && ascii_is_space(*url)) {
                url++;
        }
 
@@ -502,7 +502,7 @@ static nserror 
html_meta_refresh_process_element(html_content *c, dom_node *n)
                        url++;
        } else {
                /* url-nq */
-               while (url < end && !isspace(*url))
+               while (url < end && !ascii_is_space(*url))
                        url++;
        }
 


-- 
NetSurf Browser

_______________________________________________
netsurf-commits mailing list
[email protected]
http://listmaster.pepperfish.net/cgi-bin/mailman/listinfo/netsurf-commits-netsurf-browser.org

Reply via email to