summaryrefslogtreecommitdiffstats
path: root/kjs
diff options
context:
space:
mode:
authorSlávek Banko <slavek.banko@axis.cz>2016-09-03 15:24:45 +0200
committerSlávek Banko <slavek.banko@axis.cz>2016-09-03 15:24:56 +0200
commitfe024a800dbbbf69f282aa53af7b88ee6c2d8672 (patch)
tree934ec2f769736dca7ea4897cfa174b73ac037331 /kjs
parent0d22b7ffc6ba832bc396390dbc45a8a11efce476 (diff)
downloadtdelibs-fe024a800dbbbf69f282aa53af7b88ee6c2d8672.tar.gz
tdelibs-fe024a800dbbbf69f282aa53af7b88ee6c2d8672.zip
Fix FTBFS with GCC6
Signed-off-by: Slávek Banko <slavek.banko@axis.cz> (cherry picked from commit 0d8345e6f7f2402d3ee88c0eb3d89e0e839bc5b5)
Diffstat (limited to 'kjs')
-rwxr-xr-xkjs/create_hash_table4
1 files changed, 3 insertions, 1 deletions
diff --git a/kjs/create_hash_table b/kjs/create_hash_table
index a7df5eddf..e8103fb99 100755
--- a/kjs/create_hash_table
+++ b/kjs/create_hash_table
@@ -69,7 +69,9 @@ while (<IN>) {
my $att = $3;
my $param = $4;
push(@keys, $key);
- push(@values, $val);
+ # values in HashEntry are short but can be unsigned in C++ code
+ # therefore it is necessary to force the cast in the generated files
+ push(@values, "(short)".$val);
printf STDERR "WARNING: Number of arguments missing for $key/$val\n"
if ( $att =~ m/Function/ && length($param) == 0);
push(@attrs, length($att) > 0 ? $att : "0");