Browse Source

silence two gcc warnings

master
Felix von Leitner 15 years ago
parent
commit
43ba9a595c
2 changed files with 3 additions and 1 deletions
  1. +2
    -1
      io/iob_addbuf_internal.c
  2. +1
    -0
      t.c

+ 2
- 1
io/iob_addbuf_internal.c View File

@@ -1,9 +1,10 @@
#include <stdlib.h>
#include "iob_internal.h"

int iob_addbuf_internal(io_batch* b,const void* buf,uint64 n,int _free) {
iob_entry* e;
if (!n) {
if (_free) free(buf);
if (_free) free((char*)buf);
return 1;
}
e=array_allocate(&b->b,sizeof(iob_entry),array_length(&b->b,sizeof(iob_entry)));


+ 1
- 0
t.c View File

@@ -323,5 +323,6 @@ int main(int argc,char* argv[]) {
write(1,tmp,x);
}
#endif
return 0;
}


Loading…
Cancel
Save