=== modified file 'bin/pt-table-sync'
--- bin/pt-table-sync	2014-02-20 08:10:16 +0000
+++ bin/pt-table-sync	2014-04-23 12:01:14 +0000
@@ -10510,8 +10510,9 @@
 
       # Determine which columns to compare.
       my $ignore_columns  = $o->get('ignore-columns');
+      my %ignore_columns_lc = map { lc $_ => $ignore_columns->{$_} } keys %$ignore_columns;
       my @compare_columns = grep {
-         !$ignore_columns->{lc $_};
+         !$ignore_columns_lc{lc $_};
       } @{$o->get('columns') || $tbl_struct->{cols}};
 
       # Make sure conflict col is in compare cols else conflicting

=== modified file 't/pt-table-sync/columns.t'
--- t/pt-table-sync/columns.t	2012-07-11 18:21:47 +0000
+++ t/pt-table-sync/columns.t	2014-04-23 12:01:14 +0000
@@ -28,7 +28,7 @@
    plan skip_all => 'Cannot connect to sandbox slave';
 }
 else {
-   plan tests => 6;
+   plan tests => 7;
 }
 
 $sb->wipe_clean($master_dbh);
@@ -54,6 +54,11 @@
 $output = `$trunk/bin/pt-table-sync --ignore-columns name --print h=127.1,P=12345,u=msandbox,p=msandbox,D=test,t=test3 t=test4`;
 is($output, "", '--ignore-columns name: found no differences');
 
+# bug https://bugs.launchpad.net/percona-toolkit/+bug/1311584
+# case sensitivity of --ignore-columns was broken.
+$output = `$trunk/bin/pt-table-sync --ignore-columns Name --print h=127.1,P=12345,u=msandbox,p=msandbox,D=test,t=test5 t=test6`;
+is($output, "", '--ignore-columns Name (case sensitive): found no differences');
+
 $output = `$trunk/bin/pt-table-sync --ignore-columns id --print h=127.1,P=12345,u=msandbox,p=msandbox,D=test,t=test3 t=test4`;
 $output = remove_traces($output);
 # This test changed for the same reason as above.

=== modified file 't/pt-table-sync/samples/before.sql'
--- t/pt-table-sync/samples/before.sql	2011-06-24 22:02:05 +0000
+++ t/pt-table-sync/samples/before.sql	2014-04-23 12:01:14 +0000
@@ -28,3 +28,16 @@
 );
 insert into test3(id, name) values(15034, '51707'),(1, '001');
 insert into test4(id, name) values(15034, '051707'),(1, '1');
+
+
+create table test5 (
+  id int not null primary key,
+  Name varchar(255)
+);
+insert into test5(id, Name) values(15034, 'master'),(1, '1');
+
+create table test6 (
+  id int not null primary key,
+  Name varchar(255)
+);
+insert into test6(id, Name) values(15034, 'slave'),(1, '1');

