Rev 3908: Get rid of inline and const, to reduce warnings and errors. in http://bazaar.launchpad.net/%7Ebzr/bzr/brisbane-core

John Arbash Meinel john at arbash-meinel.com
Thu Mar 26 16:24:36 GMT 2009


At http://bazaar.launchpad.net/%7Ebzr/bzr/brisbane-core

------------------------------------------------------------
revno: 3908
revision-id: john at arbash-meinel.com-20090326162258-21e57rtpx47t6493
parent: ian.clatworthy at canonical.com-20090325121809-el4l5ie9ifqt5ur9
committer: John Arbash Meinel <john at arbash-meinel.com>
branch nick: brisbane-core
timestamp: Thu 2009-03-26 11:22:58 -0500
message:
  Get rid of inline and const, to reduce warnings and errors.
  It seems compilers don't like it if you pass &(unsigned char *) to
  (const unsigned char **), and pyrex doesn't let you define 'const unsigned char*',
  (it doesn't like const at all), so for now, just remove it, because
  it doesn't hurt anything.
  
  Removing inline because MSVC doesn't understand it, and causes compile
  failures. It wasn't really important anyway.
-------------- next part --------------
=== modified file 'bzrlib/delta.h'
--- a/bzrlib/delta.h	2009-03-19 06:01:53 +0000
+++ b/bzrlib/delta.h	2009-03-26 16:22:58 +0000
@@ -84,10 +84,10 @@
  * This must be called twice on the delta data buffer, first to get the
  * expected source buffer size, and again to get the target buffer size.
  */
-static inline unsigned long get_delta_hdr_size(const unsigned char **datap,
-                                               const unsigned char *top)
+static unsigned long
+get_delta_hdr_size(unsigned char **datap, const unsigned char *top)
 {
-    const unsigned char *data = *datap;
+    unsigned char *data = *datap;
     unsigned char cmd;
     unsigned long size = 0;
     int i = 0;



More information about the bazaar-commits mailing list