From: Tobias Mueller Date: Sun, 1 Mar 2009 15:42:50 +0000 (+0000) Subject: . (google_im_protocol_fro$ Use a const char[] instead of a const char* for X-Git-Tag: upstream/3.7.4~4184 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=3fd0c59fa51780bc536af92cbee9744f214f8675;p=platform%2Fupstream%2Fevolution-data-server.git . (google_im_protocol_fro$ Use a const char[] instead of a const char* for 2009-02-29 Tobias Mueller * backends/google/util.c: (_google_rel_from_types). (google_im_protocol_fro$ * backends/google/google-book.c (google_book_construct_base_uri): Use a const char[] instead of a const char* for a fixed sized format-string to increase auditability. ** Fixes bug 573494 svn path=/trunk/; revision=10116 --- diff --git a/addressbook/ChangeLog b/addressbook/ChangeLog index 72c4f13..acbed0e 100644 --- a/addressbook/ChangeLog +++ b/addressbook/ChangeLog @@ -1,3 +1,11 @@ +2009-02-29 Tobias Mueller + + * backends/google/util.c: (_google_rel_from_types). (google_im_protocol_from_field_name): + * backends/google/google-book.c (google_book_construct_base_uri): + Use a const char[] instead of a const char* for a fixed sized + format-string to increase auditability. + ** Fixes bug 573494 + 2009-02-25 Milan Crha ** Fix for bug #563212 diff --git a/addressbook/backends/google/google-book.c b/addressbook/backends/google/google-book.c index 26cf4cc..6d0902c 100644 --- a/addressbook/backends/google/google-book.c +++ b/addressbook/backends/google/google-book.c @@ -448,7 +448,7 @@ google_book_cache_destroy (GoogleBook *book) static void google_book_construct_base_uri (GoogleBook *book, gboolean use_ssl) { - const char *format = "%swww.google.com/m8/feeds/contacts/%s/base"; + const char format[] = "%swww.google.com/m8/feeds/contacts/%s/base"; char *esc_username; GoogleBookPrivate *priv = GET_PRIVATE (book); diff --git a/addressbook/backends/google/util.c b/addressbook/backends/google/util.c index 85731ca..8b74ff5 100644 --- a/addressbook/backends/google/util.c +++ b/addressbook/backends/google/util.c @@ -410,7 +410,7 @@ _google_rel_from_types (GList *types, const struct RelTypeMap rel_type_map[], int map_len) { - const char *format = "http://schemas.google.com/g/2005#%s"; + const char format[] = "http://schemas.google.com/g/2005#%s"; while (types) { int i; @@ -485,7 +485,7 @@ field_name_from_google_im_protocol (const char* google_protocol) static char* google_im_protocol_from_field_name (const char* field_name) { - const char *format = "http://schemas.google.com/g/2005#%s"; + const char format[] = "http://schemas.google.com/g/2005#%s"; if (NULL == field_name || strlen (field_name) < 3) {