[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: SVN 1.2.x branch: Compiler messages on windows build

From: Branko ─îibej <brane_at_xbc.nu>
Date: 2005-05-10 23:28:04 CEST

Norbert Unterberg wrote:

> I've seen some discussions about compiler messages here, so I thought
> I might add some more message when building subversion.
>
> If these compiler warnings do not matter to you, please ignore this post.

We're quite aware of those warnings. But thanks, anyway. :)

> Building http://svn.collab.net/repos/svn/branches/1.2.x
> at revision 14673.
> Compiler: Visual Studio.Net 2003, Windows XP
> Build initiated by the TortoiseSVN build script.
>
>
> \svn\Subversion\subversion\libsvn_ra_local\split_url.c(99) : warning
> C4090: 'initializing' : different 'const' qualifiers
>
> The result of svn_path_uri_decode() is assigned to a non-const char*,
> but the svn_path_uri* functions return const char*. I wonder why that
> is, since the returned path is a string allocated in a pool and does
> not need to be declared const, does it?

The problem is that, strictly speaking, that would be an API (and ABI)
change. So we didn't do that.

> \svn\Subversion\subversion\libsvn_diff\diff_file.c:
> (150) : 'function' : conversion from 'apr_off_t' to 'apr_size_t'
> (164) : 'function' : conversion from 'apr_off_t' to 'apr_size_t'
> (166) : 'function' : conversion from 'apr_off_t' to 'apr_size_t'
>
> These are about creating a map or loading a file in function
> map_or_read_file. Since I do not know what files are loaded here, I
> can not say if this might generate problems for very large files.
>
> (203) : '=' : conversion from 'apr_off_t' to 'apr_size_t',
> (257) : '=' : conversion from 'apr_off_t' to 'int'
> (306) : '=' : conversion from 'apr_off_t' to 'apr_size_t'
> (409) : 'function' : conversion from 'apr_off_t' to 'size_t'
>
> These are from chunk size calculations, so they are pretty safe. Maybe
> a type cast might prevent the warnings here.
>
> (398) : 'function' : conversion from 'apr_off_t' to 'apr_size_t'
>
> Don't know about this one...
>
> There are more compiler warnings, but they result from some generic
> type usage are probably safe. If you want to fix them, I can mail the
> other locations, too.

AFAIK none of the warnings we currently have are critical. They'll get
fixed in due time, of course, but the worst fix is the easiest one (add
a cast), so I left the warnings there as a reminder. BTW, the
apr_off_t->apr_size_t conversion warnings would show up on 64-bit
Unixes, too.

-- Brane

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Tue May 10 23:29:17 2005

This is an archived mail posted to the Subversion Dev mailing list.