You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by st...@apache.org on 2011/04/23 17:00:29 UTC
svn commit: r1096157 - in /subversion/trunk/subversion/libsvn_subr:
config_win.c stream.c
Author: stefan2
Date: Sat Apr 23 15:00:29 2011
New Revision: 1096157
URL: http://svn.apache.org/viewvc?rev=1096157&view=rev
Log:
Silence conversion warnings in VisualStudio.
* subversion/libsvn_subr/config_win.c
(parse_section): interpret data buffer as array of bytes
* subversion/libsvn_subr/stream.c
(skip_handler_apr): explicitly cast to 'apr_size_t'
Modified:
subversion/trunk/subversion/libsvn_subr/config_win.c
subversion/trunk/subversion/libsvn_subr/stream.c
Modified: subversion/trunk/subversion/libsvn_subr/config_win.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_subr/config_win.c?rev=1096157&r1=1096156&r2=1096157&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_subr/config_win.c (original)
+++ subversion/trunk/subversion/libsvn_subr/config_win.c Sat Apr 23 15:00:29 2011
@@ -130,12 +130,12 @@ parse_section(svn_config_t *cfg, HKEY hk
{
DWORD value_len = value->blocksize;
err = RegQueryValueEx(hkey, option->data, NULL, NULL,
- value->data, &value_len);
+ (LPBYTE)value->data, &value_len);
if (err == ERROR_MORE_DATA)
{
svn_stringbuf_ensure(value, value_len);
err = RegQueryValueEx(hkey, option->data, NULL, NULL,
- value->data, &value_len);
+ (LPBYTE)value->data, &value_len);
}
if (err != ERROR_SUCCESS)
return svn_error_create(SVN_ERR_MALFORMED_FILE, NULL,
Modified: subversion/trunk/subversion/libsvn_subr/stream.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_subr/stream.c?rev=1096157&r1=1096156&r2=1096157&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_subr/stream.c (original)
+++ subversion/trunk/subversion/libsvn_subr/stream.c Sat Apr 23 15:00:29 2011
@@ -855,7 +855,7 @@ skip_handler_apr(void *baton, apr_size_t
* happend and keep the *count==0 set earlier.
*/
if ((offset != new_pos) || (current == 0))
- *count = new_pos - current;
+ *count = (apr_size_t)(new_pos - current);
return err;
}
Re: svn commit: r1096157 - in
/subversion/trunk/subversion/libsvn_subr: config_win.c stream.c
Posted by Daniel Shahaf <d....@daniel.shahaf.name>.
stefan2@apache.org wrote on Sat, Apr 23, 2011 at 15:00:29 -0000:
> Modified: subversion/trunk/subversion/libsvn_subr/stream.c
> URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_subr/stream.c?rev=1096157&r1=1096156&r2=1096157&view=diff
> ==============================================================================
> --- subversion/trunk/subversion/libsvn_subr/stream.c (original)
> +++ subversion/trunk/subversion/libsvn_subr/stream.c Sat Apr 23 15:00:29 2011
> @@ -855,7 +855,7 @@ skip_handler_apr(void *baton, apr_size_t
> * happend and keep the *count==0 set earlier.
> */
> if ((offset != new_pos) || (current == 0))
> - *count = new_pos - current;
> + *count = (apr_size_t)(new_pos - current);
>
> return err;
> }
>
This is the skip API. Would it be better to change the skip API to
allow a wider type for the COUNT return parameter?
And, by the way: svn_stream_skip()'s docstring doesn't specify an @since
clause. (I haven't checked other docstrings.) Isn't it new in 1.7?
>
Re: svn commit: r1096157 - in
/subversion/trunk/subversion/libsvn_subr: config_win.c stream.c
Posted by Daniel Shahaf <d....@daniel.shahaf.name>.
stefan2@apache.org wrote on Sat, Apr 23, 2011 at 15:00:29 -0000:
> Modified: subversion/trunk/subversion/libsvn_subr/stream.c
> URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_subr/stream.c?rev=1096157&r1=1096156&r2=1096157&view=diff
> ==============================================================================
> --- subversion/trunk/subversion/libsvn_subr/stream.c (original)
> +++ subversion/trunk/subversion/libsvn_subr/stream.c Sat Apr 23 15:00:29 2011
> @@ -855,7 +855,7 @@ skip_handler_apr(void *baton, apr_size_t
> * happend and keep the *count==0 set earlier.
> */
> if ((offset != new_pos) || (current == 0))
> - *count = new_pos - current;
> + *count = (apr_size_t)(new_pos - current);
>
> return err;
> }
>
This is the skip API. Would it be better to change the skip API to
allow a wider type for the COUNT return parameter?
And, by the way: svn_stream_skip()'s docstring doesn't specify an @since
clause. (I haven't checked other docstrings.) Isn't it new in 1.7?
>