CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

Search found 3 matches
CCS Forum Index
Author Message
  Topic: memcmp unexpected --> Pointers types do not match
chux

Replies: 6
Views: 15678

PostForum: General CCS C Discussion   Posted: Mon Oct 24, 2016 5:28 pm   Subject: memcmp unexpected --> Pointers types do not match
Fair enough fellow seasoned programmer.

It does look a bit odd. as code could have been `if (dest0[i] == dest) {`. It was coded as `if (memcmp(&dest0[i], dest, sizeof(*dest)) == 0)` as that wa ...
  Topic: memcmp unexpected --> Pointers types do not match
chux

Replies: 6
Views: 15678

PostForum: General CCS C Discussion   Posted: Mon Oct 24, 2016 3:34 pm   Subject: memcmp unexpected --> Pointers types do not match
Uploaded to the recent 5.064 version and the problem went away - yeah!

Thanks

Concerning "your third parameter seems odd. taking the sizeof of a pointer is not correct usually." Hope ...
  Topic: memcmp unexpected --> Pointers types do not match
chux

Replies: 6
Views: 15678

PostForum: General CCS C Discussion   Posted: Mon Oct 24, 2016 1:07 pm   Subject: memcmp unexpected --> Pointers types do not match
In <string.h>, memcmp() has the definition


// <string.h>
signed int8 memcmp(void * s1,void *s2,size_t n)

// my code
unsigned foo(uint64_t *dest) {
uint64_ ...
 
Page 1 of 1
All times are GMT - 6 Hours
Jump to:  


Powered by phpBB © 2001, 2005 phpBB Group