Login | ViewVC Help
View File | Revision Log | Show Annotations | Download File | View Changeset | Root Listing
root/filter_foundry/trunk/telegraphics_common/tt/str.c
(Generate patch)

Comparing trunk/telegraphics_common/tt/str.c (file contents):
Revision 354 by daniel-marschall, Sat Jul 31 22:39:23 2021 UTC vs.
Revision 355 by daniel-marschall, Tue Oct 5 13:41:45 2021 UTC

# Line 63 | Line 63 | char *cat(char *d,char *s){
63          return d;
64   }
65  
66 + /*
67   void *my_memset(void *dst, int val, size_t len){
68          char *p;
69          for(p=(char*)dst;len--;)
70                  *p++ = val;
71          return dst;
72   }
73 + */
74 +
75 + // my_strdup() is like _strdup(), with the difference that it accepts "char*" instead of "const char*" as argument
76   char *my_strdup(char *s){
77          size_t n = strlen(s);
78          char *p = (char*)malloc(n+1);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines