]> git.draconx.ca Git - upkg.git/commitdiff
libupkg: Add const qualifier to upkg_decode_index input buffer.
authorNick Bowler <nbowler@draconx.ca>
Fri, 4 May 2012 21:22:12 +0000 (17:22 -0400)
committerNick Bowler <nbowler@draconx.ca>
Tue, 8 May 2012 23:46:28 +0000 (19:46 -0400)
src/libupkg.c
src/upkg.h

index 3ecce7fbbd50c934e090a959950b590e937abec6..5a9dce7f29ad0d8ec6936827f01b5181d6d89c67 100644 (file)
@@ -110,7 +110,7 @@ const struct upkg_file_ops upkg_default_fops = {
  * Stores the result in *val and returns the number of input bytes read (or 0
  * if the input is invalid, in which case *val is undefined).
  */
-size_t upkg_decode_index(long *val, unsigned char *bytes, size_t n)
+size_t upkg_decode_index(long *val, const unsigned char *bytes, size_t n)
 {
        *val = 0;
 
index 2885643b269cede5a1ea1698a69c1bdfa0e7aa35..34291b7f7bf18717e6256dfe18441e65b2cca9be 100644 (file)
@@ -115,6 +115,6 @@ int    upkg_export_seek(struct upkg_file *f, long offset, int whence);
 long   upkg_export_tell(struct upkg_file *f);
 void   upkg_export_close(struct upkg_file *f);
 
-size_t upkg_decode_index(long *val, unsigned char *bytes, size_t n);
+size_t upkg_decode_index(long *val, const unsigned char *bytes, size_t n);
 
 #endif