/** @brief Strip whitespace (or other characters) from the beginning of a string.
*
- * Strips the whitespaces from the begining of s.
+ * Strips the whitespaces from the beginning of s.
* By default (when char_list=nullptr), these characters get stripped:
*
* - " " (ASCII 32 (0x20)) space.
memmove(s, cur, strlen(cur) + 1);
}
-/** @brief Strip whitespace (or other characters) from the end and the begining of a string.
+/** @brief Strip whitespace (or other characters) from the end and the beginning of a string.
*
* Strips the whitespaces from both the beginning and the end of s.
* By default (when char_list=nullptr), these characters get stripped:
* @param str the string to modify
* @param from char to search
* @param to char to put instead
- * @param occurence number of changes to do (=0 means all)
+ * @param occurrence number of changes to do (=0 means all)
*/
void xbt_str_subst(char *str, char from, char to, int occurence)
{
/** @brief Join a set of strings as a single string */
char *xbt_str_join(xbt_dynar_t dyn, const char *sep)
{
- int len = 1, dyn_len = xbt_dynar_length(dyn);
+ int len = 1;
+ int dyn_len = xbt_dynar_length(dyn);
unsigned int cpt;
char* cursor;