shntool-3.0.10-large-size.diff 877 B

1234567891011121314151617181920212223
  1. diff -aur shntool-3.0.10-clean/src/core_fileio.c shntool-3.0.10-size/src/core_fileio.c
  2. --- shntool-3.0.10-clean/src/core_fileio.c 2009-03-11 17:18:01.000000000 +0000
  3. +++ shntool-3.0.10-size/src/core_fileio.c 2012-08-11 17:20:14.000000000 +0100
  4. @@ -110,10 +110,16 @@
  5. buf[4] = 0;
  6. if (be_val)
  7. - *be_val = (buf[0] << 24) | (buf[1] << 16) | (buf[2] << 8) | buf[3];
  8. + *be_val = (((unsigned long)buf[0]) << 24)
  9. + | (((unsigned long)buf[1]) << 16)
  10. + | (((unsigned long)buf[2]) << 8)
  11. + | ((unsigned long)buf[3]);
  12. if (le_val)
  13. - *le_val = (buf[3] << 24) | (buf[2] << 16) | (buf[1] << 8) | buf[0];
  14. + *le_val = (((unsigned long)buf[3]) << 24)
  15. + | (((unsigned long)buf[2]) << 16)
  16. + | (((unsigned long)buf[1]) << 8)
  17. + | ((unsigned long)buf[0]);
  18. if (tag_val)
  19. tagcpy(tag_val,buf);