title: Git changes files on Mac OS X
body: <p>I just cloned an old repository containing some linux kernel modules (don't ask).
  If I clone on a linux machine, everything is fine. On my Mac however, someone (presumably Mac OS X) makes binary changes to the modules. I already disabled autocrlf.</p>
  
  <p>Here's the output of <code>git diff -p --stat</code> <em>directly</em> after clone:</p>
  
  <pre><code> .../kernel/net/ipv4/netfilter/ipt_ecn.ko           |  Bin 3853 -&gt; 4535 bytes
   .../kernel/net/ipv4/netfilter/ipt_ttl.ko           |  Bin 3458 -&gt; 3904 bytes
   .../kernel/net/netfilter/xt_connmark.ko            |  Bin 4534 -&gt; 5618 bytes
   .../2.6.26-2-686/kernel/net/netfilter/xt_dscp.ko   |  Bin 4378 -&gt; 5217 bytes
   .../2.6.26-2-686/kernel/net/netfilter/xt_mark.ko   |  Bin 3679 -&gt; 4334 bytes
   .../kernel/net/netfilter/xt_rateest.ko             |  Bin 4545 -&gt; 7137 bytes
   .../2.6.26-2-686/kernel/net/netfilter/xt_tcpmss.ko |  Bin 3841 -&gt; 6553 bytes
   7 files changed, 0 insertions(+), 0 deletions(-)
  
  diff --git a/i686/modules/2.6.26-2-686/kernel/net/ipv4/netfilter/ipt_ecn.ko b/i686/modules/2.6.26-2-686/kernel/net/ipv4/netfilter/ipt_ecn.ko
  index 76d7d8d..b1470d6 100644
  Binary files a/i686/modules/2.6.26-2-686/kernel/net/ipv4/netfilter/ipt_ecn.ko and b/i686/modules/2.6.26-2-686/kernel/net/ipv4/netfilter/ipt_ecn.ko differ
  diff --git a/i686/modules/2.6.26-2-686/kernel/net/ipv4/netfilter/ipt_ttl.ko b/i686/modules/2.6.26-2-686/kernel/net/ipv4/netfilter/ipt_ttl.ko
  index d974dc9..9dcb633 100644
  Binary files a/i686/modules/2.6.26-2-686/kernel/net/ipv4/netfilter/ipt_ttl.ko and b/i686/modules/2.6.26-2-686/kernel/net/ipv4/netfilter/ipt_ttl.ko differ
  diff --git a/i686/modules/2.6.26-2-686/kernel/net/netfilter/xt_connmark.ko b/i686/modules/2.6.26-2-686/kernel/net/netfilter/xt_connmark.ko
  index d9381a6..14c2a2c 100644
  Binary files a/i686/modules/2.6.26-2-686/kernel/net/netfilter/xt_connmark.ko and b/i686/modules/2.6.26-2-686/kernel/net/netfilter/xt_connmark.ko differ
  diff --git a/i686/modules/2.6.26-2-686/kernel/net/netfilter/xt_dscp.ko b/i686/modules/2.6.26-2-686/kernel/net/netfilter/xt_dscp.ko
  index 36af201..178adfa 100644
  Binary files a/i686/modules/2.6.26-2-686/kernel/net/netfilter/xt_dscp.ko and b/i686/modules/2.6.26-2-686/kernel/net/netfilter/xt_dscp.ko differ
  diff --git a/i686/modules/2.6.26-2-686/kernel/net/netfilter/xt_mark.ko b/i686/modules/2.6.26-2-686/kernel/net/netfilter/xt_mark.ko
  index 2dd1a0a..1329162 100644
  Binary files a/i686/modules/2.6.26-2-686/kernel/net/netfilter/xt_mark.ko and b/i686/modules/2.6.26-2-686/kernel/net/netfilter/xt_mark.ko differ
  diff --git a/i686/modules/2.6.26-2-686/kernel/net/netfilter/xt_rateest.ko b/i686/modules/2.6.26-2-686/kernel/net/netfilter/xt_rateest.ko
  index 8678387..b23e514 100644
  Binary files a/i686/modules/2.6.26-2-686/kernel/net/netfilter/xt_rateest.ko and b/i686/modules/2.6.26-2-686/kernel/net/netfilter/xt_rateest.ko differ
  diff --git a/i686/modules/2.6.26-2-686/kernel/net/netfilter/xt_tcpmss.ko b/i686/modules/2.6.26-2-686/kernel/net/netfilter/xt_tcpmss.ko
  index 13e4891..7c3c61c 100644
  Binary files a/i686/modules/2.6.26-2-686/kernel/net/netfilter/xt_tcpmss.ko and b/i686/modules/2.6.26-2-686/kernel/net/netfilter/xt_tcpmss.ko differ
  </code></pre>
  
  <p>A <code>git reset --hard</code> doesn't do the trick, either. Something weird does happen, though: Every time, I do the reset, the sizes on the right of <code>git diff</code> switch places and some capitalizations in the filenames change. I do have a case-insensitive filesystem on the Mac, could that be the cause of this? How could I fix this (if possible, without reformatting the Mac)</p>