Opened 9 years ago
Closed 7 years ago
#12762 closed bug (fixed)
[Patch] apps/serialconnect/encoding.c: fix gcc6 build
Reported by: | mt | Owned by: | pulkomandy |
---|---|---|---|
Priority: | normal | Milestone: | Unscheduled |
Component: | Applications | Version: | R1/Development |
Keywords: | apps/serialconnect | Cc: | |
Blocked By: | Blocking: | ||
Platform: | All |
Description
Reindent source code, to fix gcc6 '-Werror=misleading-indentation' warnings.
Cc /home/haiku/haiku/haiku/generated-gcc6/objects/haiku/x86/release/apps/serialconnect/encoding.o /home/haiku/haiku/haiku/src/apps/serialconnect/libvterm/src/encoding.c: In function 'decode_utf8': /home/haiku/haiku/haiku/src/apps/serialconnect/libvterm/src/encoding.c:77:11: error: this 'if' clause does not guard... [-Werror=misleading-indentation] if(data->this_cp < 0x0080) data->this_cp = UNICODE_INVALID; break; ^~ /home/haiku/haiku/haiku/src/apps/serialconnect/libvterm/src/encoding.c:77:72: note: ...this statement, but the latter is misleadingly indented as if it is guarded by the 'if' if(data->this_cp < 0x0080) data->this_cp = UNICODE_INVALID; break; ^~~~~ /home/haiku/haiku/haiku/src/apps/serialconnect/libvterm/src/encoding.c:79:11: error: this 'if' clause does not guard... [-Werror=misleading-indentation] if(data->this_cp < 0x0800) data->this_cp = UNICODE_INVALID; break; ^~ /home/haiku/haiku/haiku/src/apps/serialconnect/libvterm/src/encoding.c:79:72: note: ...this statement, but the latter is misleadingly indented as if it is guarded by the 'if' if(data->this_cp < 0x0800) data->this_cp = UNICODE_INVALID; break; ^~~~~ /home/haiku/haiku/haiku/src/apps/serialconnect/libvterm/src/encoding.c:81:11: error: this 'if' clause does not guard... [-Werror=misleading-indentation] if(data->this_cp < 0x10000) data->this_cp = UNICODE_INVALID; break; ^~ /home/haiku/haiku/haiku/src/apps/serialconnect/libvterm/src/encoding.c:81:72: note: ...this statement, but the latter is misleadingly indented as if it is guarded by the 'if' if(data->this_cp < 0x10000) data->this_cp = UNICODE_INVALID; break; ^~~~~ /home/haiku/haiku/haiku/src/apps/serialconnect/libvterm/src/encoding.c:83:11: error: this 'if' clause does not guard... [-Werror=misleading-indentation] if(data->this_cp < 0x200000) data->this_cp = UNICODE_INVALID; break; ^~ /home/haiku/haiku/haiku/src/apps/serialconnect/libvterm/src/encoding.c:83:73: note: ...this statement, but the latter is misleadingly indented as if it is guarded by the 'if' if(data->this_cp < 0x200000) data->this_cp = UNICODE_INVALID; break; ^~~~~ /home/haiku/haiku/haiku/src/apps/serialconnect/libvterm/src/encoding.c:85:11: error: this 'if' clause does not guard... [-Werror=misleading-indentation] if(data->this_cp < 0x4000000) data->this_cp = UNICODE_INVALID; break; ^~ /home/haiku/haiku/haiku/src/apps/serialconnect/libvterm/src/encoding.c:85:74: note: ...this statement, but the latter is misleadingly indented as if it is guarded by the 'if' if(data->this_cp < 0x4000000) data->this_cp = UNICODE_INVALID; break; ^~~~~ cc1: all warnings being treated as errors
Attachments (1)
Change History (5)
by , 9 years ago
Attachment: | 0014-encoding.c-fix-gcc6-build.patch added |
---|
comment:1 by , 9 years ago
patch: | 0 → 1 |
---|
comment:2 by , 9 years ago
Owner: | changed from | to
---|---|
Status: | new → assigned |
comment:3 by , 9 years ago
comment:4 by , 7 years ago
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Fixed in c95da8e7006d90 by applying upstream changes.
Note:
See TracTickets
for help on using tickets.
Looks correct, but maybe we should see if upstream libvterm has the changes already. And maybe we should make libvterm an external package?