Advertisement
Guest User

Untitled

a guest
Oct 23rd, 2018
74
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 11.50 KB | None | 0 0
  1. sao.c: In function 'trim':
  2. sao.c:71:12: warning: implicit declaration of function 'isspace' [-Wimplicit-function-declaration]
  3. while (isspace(str[begin])) begin++;
  4. ^~~~~~~
  5. sao.c: In function 'epollEventLoop':
  6. sao.c:250:93: warning: pointer targets in passing argument 1 of 'fdgets' differ in signedness [-Wpointer-sign]
  7. while(memset(buf, 0, sizeof buf) && (count = fdgets(buf, sizeof buf, thefd)) > 0)
  8. ^~~
  9. sao.c:60:5: note: expected 'unsigned char *' but argument is of type 'char *'
  10. int fdgets(unsigned char *buffer, int bufferSize, int fd)
  11. ^~~~~~
  12. sao.c:262:65: warning: passing argument 1 of 'fprintf' discards 'volatile' qualifier from pointer target type [-Wdiscarded-qualifiers]
  13. fprintf(telFD, "%s\n", line);
  14. ^~~~~
  15. In file included from sao.c:19:0:
  16. /usr/include/stdio.h:358:12: note: expected 'FILE * restrict {aka struct _IO_FILE * restrict}' but argument is of type 'volatile FILE * {aka volatile struct _IO_FILE *}'
  17. extern int fprintf (FILE *__restrict __stream,
  18. ^~~~~~~
  19. sao.c:263:64: warning: passing argument 1 of 'fflush' discards 'volatile' qualifier from pointer target type [-Wdiscarded-qualifiers]
  20. fflush(telFD);
  21. ^~~~~
  22. In file included from sao.c:19:0:
  23. /usr/include/stdio.h:244:12: note: expected 'FILE * {aka struct _IO_FILE *}' but argument is of type 'volatile FILE * {aka volatile struct _IO_FILE *}'
  24. extern int fflush (FILE *__stream);
  25. ^~~~~~
  26. sao.c:269:63: warning: unused variable 'line' [-Wunused-variable]
  27. char *line = strstr(buf, "PROBING");
  28. ^~~~
  29. sao.c:275:63: warning: unused variable 'line' [-Wunused-variable]
  30. char *line = strstr(buf, "REMOVING PROBE");
  31. ^~~~
  32. sao.c: In function 'titleWriter':
  33. sao.c:324:21: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
  34. int thefd = (int)sock;
  35. ^
  36. sao.c:330:77: warning: 'return' with no value, in function returning non-void
  37. if(send(thefd, string, strlen(string), MSG_NOSIGNAL) == -1) return;
  38. ^~~~~~
  39. sao.c:322:7: note: declared here
  40. void *titleWriter(void *sock)
  41. ^~~~~~~~~~~
  42. sao.c: In function 'telnetWorker':
  43. sao.c:379:21: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
  44. int thefd = (int)sock;
  45. ^
  46. sao.c:406:32: error: invalid operands to binary % (have 'char *' and 'int')
  47. fscanf(fp, "%s %s" %i, accounts[j].id, accounts[j].password);
  48. ~~~~~~~ ^
  49. sao.c:411:19: warning: pointer targets in passing argument 1 of 'fdgets' differ in signedness [-Wpointer-sign]
  50. if(fdgets(buf, sizeof buf, thefd) < 1) goto end;
  51. ^~~
  52. sao.c:60:5: note: expected 'unsigned char *' but argument is of type 'char *'
  53. int fdgets(unsigned char *buffer, int bufferSize, int fd)
  54. ^~~~~~
  55. sao.c:416:27: warning: left-hand operand of comma expression has no effect [-Wunused-value]
  56. nickstring = ("%s", buf);
  57. ^
  58. sao.c:421:19: warning: pointer targets in passing argument 1 of 'fdgets' differ in signedness [-Wpointer-sign]
  59. if(fdgets(buf, sizeof buf, thefd) < 1) goto end;
  60. ^~~
  61. sao.c:60:5: note: expected 'unsigned char *' but argument is of type 'char *'
  62. int fdgets(unsigned char *buffer, int bufferSize, int fd)
  63. ^~~~~~
  64. sao.c:441:20: warning: too many arguments for format [-Wformat-extra-args]
  65. sprintf(bashline,"\x1b[35;1m[\x1b[37;1m%s\x1b[35;1m@\x1b[37;1mシノア\x1b[35;1m]\x1b[36;1m~#\x1b[0m",accounts[find_line].id, buf);
  66. ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  67. sao.c:450:22: warning: pointer targets in passing argument 1 of 'fdgets' differ in signedness [-Wpointer-sign]
  68. while(fdgets(buf, sizeof buf, thefd) > 0)
  69. ^~~
  70. sao.c:60:5: note: expected 'unsigned char *' but argument is of type 'char *'
  71. int fdgets(unsigned char *buffer, int bufferSize, int fd)
  72. ^~~~~~
  73. sao.c:455:69: warning: 'return' with no value, in function returning non-void
  74. if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
  75. ^~~~~~
  76. sao.c:376:7: note: declared here
  77. void *telnetWorker(void *sock)
  78. ^~~~~~~~~~~~
  79. sao.c:460:69: warning: 'return' with no value, in function returning non-void
  80. if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
  81. ^~~~~~
  82. sao.c:376:7: note: declared here
  83. void *telnetWorker(void *sock)
  84. ^~~~~~~~~~~~
  85. sao.c:465:69: warning: 'return' with no value, in function returning non-void
  86. if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
  87. ^~~~~~
  88. sao.c:376:7: note: declared here
  89. void *telnetWorker(void *sock)
  90. ^~~~~~~~~~~~
  91. sao.c:470:69: warning: 'return' with no value, in function returning non-void
  92. if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
  93. ^~~~~~
  94. sao.c:376:7: note: declared here
  95. void *telnetWorker(void *sock)
  96. ^~~~~~~~~~~~
  97. sao.c:475:69: warning: 'return' with no value, in function returning non-void
  98. if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
  99. ^~~~~~
  100. sao.c:376:7: note: declared here
  101. void *telnetWorker(void *sock)
  102. ^~~~~~~~~~~~
  103. sao.c:480:69: warning: 'return' with no value, in function returning non-void
  104. if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
  105. ^~~~~~
  106. sao.c:376:7: note: declared here
  107. void *telnetWorker(void *sock)
  108. ^~~~~~~~~~~~
  109. sao.c:485:69: warning: 'return' with no value, in function returning non-void
  110. if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
  111. ^~~~~~
  112. sao.c:376:7: note: declared here
  113. void *telnetWorker(void *sock)
  114. ^~~~~~~~~~~~
  115. sao.c:490:69: warning: 'return' with no value, in function returning non-void
  116. if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
  117. ^~~~~~
  118. sao.c:376:7: note: declared here
  119. void *telnetWorker(void *sock)
  120. ^~~~~~~~~~~~
  121. sao.c:495:69: warning: 'return' with no value, in function returning non-void
  122. if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
  123. ^~~~~~
  124. sao.c:376:7: note: declared here
  125. void *telnetWorker(void *sock)
  126. ^~~~~~~~~~~~
  127. sao.c:500:69: warning: 'return' with no value, in function returning non-void
  128. if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
  129. ^~~~~~
  130. sao.c:376:7: note: declared here
  131. void *telnetWorker(void *sock)
  132. ^~~~~~~~~~~~
  133. sao.c:505:69: warning: 'return' with no value, in function returning non-void
  134. if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
  135. ^~~~~~
  136. sao.c:376:7: note: declared here
  137. void *telnetWorker(void *sock)
  138. ^~~~~~~~~~~~
  139. sao.c:510:69: warning: 'return' with no value, in function returning non-void
  140. if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
  141. ^~~~~~
  142. sao.c:376:7: note: declared here
  143. void *telnetWorker(void *sock)
  144. ^~~~~~~~~~~~
  145. sao.c:517:22: warning: unused variable 'helpline4' [-Wunused-variable]
  146. char helpline4 [80];
  147. ^~~~~~~~~
  148. sao.c:572:22: warning: unused variable 'extraline7' [-Wunused-variable]
  149. char extraline7 [80];
  150. ^~~~~~~~~~
  151. sao.c:571:22: warning: unused variable 'extraline6' [-Wunused-variable]
  152. char extraline6 [80];
  153. ^~~~~~~~~~
  154. sao.c:570:22: warning: unused variable 'extraline5' [-Wunused-variable]
  155. char extraline5 [80];
  156. ^~~~~~~~~~
  157. sao.c:765:27: warning: too many arguments for format [-Wformat-extra-args]
  158. sprintf(botnet, "Thanks for buying %s see you next time\r\n", accounts[find_line].id, buf);
  159. ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  160. sao.c:766:71: warning: 'return' with no value, in function returning non-void
  161. if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
  162. ^~~~~~
  163. sao.c:376:7: note: declared here
  164. void *telnetWorker(void *sock)
  165. ^~~~~~~~~~~~
  166. sao.c:437:9: warning: label 'Title' defined but not used [-Wunused-label]
  167. Title:
  168. ^~~~~
  169. sao.c:395:13: warning: variable 'c' set but not used [-Wunused-but-set-variable]
  170. int c;
  171. ^
  172. sao.c:388:15: warning: unused variable 'password' [-Wunused-variable]
  173. char* password;
  174. ^~~~~~~~
  175. sao.c:387:15: warning: unused variable 'username' [-Wunused-variable]
  176. char* username;
  177. ^~~~~~~~
  178. sao.c: In function 'telnetListener':
  179. sao.c:810:55: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
  180. pthread_create( &thread, NULL, &telnetWorker, (void *)newsockfd); }
  181. ^
  182. sao.c: At top level:
  183. sao.c:813:5: warning: third argument of 'main' should probably be 'char **' [-Wmain]
  184. int main (int argc, char *argv[], void *sock)
  185. ^~~~
  186. sao.c: In function 'main':
  187. sao.c:856:42: warning: passing argument 3 of 'pthread_create' from incompatible pointer type [-Wincompatible-pointer-types]
  188. pthread_create(&thread[0], NULL, &telnetListener, port);
  189. ^
  190. In file included from sao.c:30:0:
  191. /usr/include/pthread.h:233:12: note: expected 'void * (*)(void *)' but argument is of type 'void * (*)(int)'
  192. extern int pthread_create (pthread_t *__restrict __newthread,
  193. ^~~~~~~~~~~~~~
  194. sao.c:856:59: warning: passing argument 4 of 'pthread_create' makes pointer from integer without a cast [-Wint-conversion]
  195. pthread_create(&thread[0], NULL, &telnetListener, port);
  196. ^~~~
  197. In file included from sao.c:30:0:
  198. /usr/include/pthread.h:233:12: note: expected 'void * restrict' but argument is of type 'int'
  199. extern int pthread_create (pthread_t *__restrict __newthread,
  200. ^~~~~~~~~~~~~~
  201. At top level:
  202. sao.c:53:23: warning: 'fileFD' defined but not used [-Wunused-variable]
  203. static volatile FILE *fileFD;
  204. ^~~~~~
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement