diff options
| author | Dmitry Antipov | 2013-08-14 08:27:32 +0400 |
|---|---|---|
| committer | Dmitry Antipov | 2013-08-14 08:27:32 +0400 |
| commit | da5707e8ec8df0a8a9bb1a1f12c6b701314845cc (patch) | |
| tree | f760c12fbef60ff4d1db6ddb26cdecdff1086dae | |
| parent | 25554267037ced56fdaed17e3a09d8926b70f978 (diff) | |
| download | emacs-da5707e8ec8df0a8a9bb1a1f12c6b701314845cc.tar.gz emacs-da5707e8ec8df0a8a9bb1a1f12c6b701314845cc.zip | |
Fix --enable-gcc-warnings errors introduced in 2013-08-13 commit.
* image.c (imagemagick_filename_hint): Use `const char *' and
prefer SSDATA to SDATA to avoid warnings.
| -rw-r--r-- | src/ChangeLog | 6 | ||||
| -rw-r--r-- | src/image.c | 10 |
2 files changed, 11 insertions, 5 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index af088340e3b..cf73204c55c 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,5 +1,11 @@ | |||
| 1 | 2013-08-14 Dmitry Antipov <dmantipov@yandex.ru> | 1 | 2013-08-14 Dmitry Antipov <dmantipov@yandex.ru> |
| 2 | 2 | ||
| 3 | Fix --enable-gcc-warnings errors introduced in 2013-08-13 commit. | ||
| 4 | * image.c (imagemagick_filename_hint): Use `const char *' and | ||
| 5 | prefer SSDATA to SDATA to avoid warnings. | ||
| 6 | |||
| 7 | 2013-08-14 Dmitry Antipov <dmantipov@yandex.ru> | ||
| 8 | |||
| 3 | Cleanup window fringes, margins and scroll bars adjustments. | 9 | Cleanup window fringes, margins and scroll bars adjustments. |
| 4 | * window.c (set_window_fringes, set_window_margins) | 10 | * window.c (set_window_fringes, set_window_margins) |
| 5 | (set_window_scroll_bars, apply_window_adjustment): New functions. | 11 | (set_window_scroll_bars, apply_window_adjustment): New functions. |
diff --git a/src/image.c b/src/image.c index e767d5447d1..99bb9d8c135 100644 --- a/src/image.c +++ b/src/image.c | |||
| @@ -7851,9 +7851,9 @@ static char* | |||
| 7851 | imagemagick_filename_hint (Lisp_Object spec) | 7851 | imagemagick_filename_hint (Lisp_Object spec) |
| 7852 | { | 7852 | { |
| 7853 | Lisp_Object format = image_spec_value (spec, intern (":format"), NULL); | 7853 | Lisp_Object format = image_spec_value (spec, intern (":format"), NULL); |
| 7854 | Lisp_Object symbol = intern ("image-format-suffixes"); | 7854 | Lisp_Object val, symbol = intern ("image-format-suffixes"); |
| 7855 | Lisp_Object val; | 7855 | const char *prefix = "/tmp/foo."; |
| 7856 | char *name, *prefix = "/tmp/foo."; | 7856 | char *name; |
| 7857 | 7857 | ||
| 7858 | if (NILP (Fboundp (symbol))) | 7858 | if (NILP (Fboundp (symbol))) |
| 7859 | return NULL; | 7859 | return NULL; |
| @@ -7871,8 +7871,8 @@ imagemagick_filename_hint (Lisp_Object spec) | |||
| 7871 | return NULL; | 7871 | return NULL; |
| 7872 | 7872 | ||
| 7873 | name = xmalloc (strlen (prefix) + SBYTES (val) + 1); | 7873 | name = xmalloc (strlen (prefix) + SBYTES (val) + 1); |
| 7874 | strcpy(name, prefix); | 7874 | strcpy (name, prefix); |
| 7875 | strcat(name, SDATA (val)); | 7875 | strcat (name, SSDATA (val)); |
| 7876 | return name; | 7876 | return name; |
| 7877 | } | 7877 | } |
| 7878 | 7878 | ||