Skip to content

Commit 85078f4

Browse files
d-a-vigrr
authored andcommitted
yet less warnings for Wall Wextra guys
1 parent fed9251 commit 85078f4

File tree

3 files changed

+9
-3
lines changed

3 files changed

+9
-3
lines changed

libraries/ESP8266mDNS/ESP8266mDNS.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -907,7 +907,7 @@ void MDNSResponder::_replyToTypeEnumRequest(IPAddress multicastInterface) {
907907
if(servicePtr->_port > 0){
908908
char *service = servicePtr->_name;
909909
char *proto = servicePtr->_proto;
910-
uint16_t port = servicePtr->_port;
910+
//uint16_t port = servicePtr->_port;
911911

912912
#ifdef MDNS_DEBUG_TX
913913
Serial.printf("TX: service:%s, proto:%s\n", service, proto);

libraries/GDBStub/src/internal/gdbstub.c

+3-2
Original file line numberDiff line numberDiff line change
@@ -291,7 +291,7 @@ static void ATTR_GDBFN sendReason() {
291291
#endif
292292
//exception-to-signal mapping
293293
char exceptionSignal[]={4,31,11,11,2,6,8,0,6,7,0,0,7,7,7,7};
294-
int i=0;
294+
unsigned int i=0;
295295
gdbPacketStart();
296296
gdbPacketChar('T');
297297
if (gdbstub_savedRegs.reason==0xff) {
@@ -321,6 +321,7 @@ static void ATTR_GDBFN sendReason() {
321321

322322
//Handle a command as received from GDB.
323323
static int ATTR_GDBFN gdbHandleCommand(unsigned char *cmd, int len) {
324+
(void)len; // unused
324325
//Handle a command
325326
int i, j, k;
326327
unsigned char *data=cmd+1;
@@ -657,7 +658,7 @@ static void ATTR_GDBFN gdb_semihost_putchar1(char c) {
657658
//The OS-less SDK uses the Xtensa HAL to handle exceptions. We can use those functions to catch any
658659
//fatal exceptions and invoke the debugger when this happens.
659660
static void ATTR_GDBINIT install_exceptions() {
660-
int i;
661+
unsigned int i;
661662
int exno[]={EXCCAUSE_ILLEGAL, EXCCAUSE_SYSCALL, EXCCAUSE_INSTR_ERROR, EXCCAUSE_LOAD_STORE_ERROR,
662663
EXCCAUSE_DIVIDE_BY_ZERO, EXCCAUSE_UNALIGNED, EXCCAUSE_INSTR_DATA_ERROR, EXCCAUSE_LOAD_STORE_DATA_ERROR,
663664
EXCCAUSE_INSTR_ADDR_ERROR, EXCCAUSE_LOAD_STORE_ADDR_ERROR, EXCCAUSE_INSTR_PROHIBITED,

libraries/Wire/Wire.cpp

+5
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,7 @@ void TwoWire::begin(void){
7171
}
7272

7373
void TwoWire::begin(uint8_t address){
74+
(void)address;
7475
// twi_setAddress(address);
7576
// twi_attachSlaveTxEvent(onRequestService);
7677
// twi_attachSlaveRxEvent(onReceiveService);
@@ -206,6 +207,8 @@ void TwoWire::flush(void){
206207

207208
void TwoWire::onReceiveService(uint8_t* inBytes, int numBytes)
208209
{
210+
(void)inBytes;
211+
(void)numBytes;
209212
// don't bother if user hasn't registered a callback
210213
// if(!user_onReceive){
211214
// return;
@@ -242,10 +245,12 @@ void TwoWire::onRequestService(void){
242245
}
243246

244247
void TwoWire::onReceive( void (*function)(int) ){
248+
(void)function;
245249
//user_onReceive = function;
246250
}
247251

248252
void TwoWire::onRequest( void (*function)(void) ){
253+
(void)function;
249254
//user_onRequest = function;
250255
}
251256

0 commit comments

Comments
 (0)