Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable additional keys, remove lock files, fix clipboard under WSL, reduce binary size #103

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

TobiasKarnat
Copy link

No description provided.

@TobiasKarnat
Copy link
Author

I have now additionally removed dead code and fixed almost all compiler warnings.
But I'm unsure how to solve the -Wsign-compare warnings, can you have a look (with -Wextra)?

gcs.c: In function ‘_getfillgc2’:
gcs.c:241:20: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
             if(val == ~0)
                    ^~
gcs.c:247:20: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
             if(val == ~0)
                    ^~
gcs.c:254:20: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
             if(val == ~0)
                    ^~
frptofchar.c: In function ‘_frptofcharptb’:
frptofchar.c:16:14: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
         if(p < (l=NRUNE(b))){
              ^
cmd.c: In function ‘inputc’:
cmd.c:113:15: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
         if (r == WEOF && errno == EILSEQ){
               ^~
file.c: In function ‘Fupdate’:
file.c:341:11: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
     if(p0 > f->markp+sizeof(Posn)/RUNESIZE){    /* for undo, this throws away the undo transcript */
           ^
io.c: In function ‘writef’:
io.c:50:20: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
             (f->dev!=dev || f->qid!=qid || f->date<mtime)){
                    ^~
io.c:50:35: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
             (f->dev!=dev || f->qid!=qid || f->date<mtime)){
                                   ^~
io.c: In function ‘readio’:
io.c:94:20: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
         if (buf[0] == WEOF){
                    ^~
regexp.c: In function ‘classmatch’:
regexp.c:517:15: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
         if(*p == 0xFFFFFFFF){
               ^~
string.c: In function ‘Strinsure’:
string.c:70:16: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
     if(p->size < n){    /* p needs to grow */
                ^
sys.c: In function ‘Write’:
sys.c:39:11: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
     if (m != n)
           ^~
menu.c: In function ‘genmenu3’:
menu.c:383:20: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
     while(i<mw && k<sizeof buf-1){
                    ^
mesg.c: In function ‘outlong’:
mesg.c:464:18: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
     for(i = 0; i < sizeof(buf); i++, l >>= 8)
                  ^
rasp.c: In function ‘rload’:
rasp.c:184:40: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
     for(p=0,s=r->sect; s && p+s->nrunes<=p0; s=s->next)
                                        ^~
rasp.c:186:12: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
     while(p<p1 && s){
            ^
rasp.c:195:17: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
             if(n>p1-p0) /* all in this section */
                 ^
rasp.c: In function ‘rmissing’:
rasp.c:217:40: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
     for(p=0,s=r->sect; s && p+s->nrunes<=p0; s=s->next)
                                        ^~
rasp.c:219:12: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
     while(p<p1 && s){
            ^
rasp.c:222:18: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
             if(n > p1-p0)   /* all in this section */
                  ^
rasp.c: In function ‘rcontig’:
rasp.c:240:40: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
     for(p=0,s=r->sect; s && p+s->nrunes<=p0; s=s->next)
                                        ^~
rasp.c:242:12: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
     while(p<p1 && s && (text ? (s->text!=0) : (s->text==0))){
            ^
rasp.c:244:14: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
         if(n > p1-p0)   /* all in this section */
              ^

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant