-char *util_strsws(char *skip, char **move) {
- size_t size = 0;
- if (!skip)
- return NULL;
-
- while (*skip == ' ' || *skip == '\t')
- skip++,size++;
- *move = skip;
- return skip-size;
+bool util_strupper(const char *str) {
+ while (*str) {
+ if(!isupper(*str))
+ return false;
+ str++;
+ }
+ return true;
+}
+
+/*
+ * Returns true if string is all digits, otherwise
+ * it returns false.
+ */
+bool util_strdigit(const char *str) {
+ while (*str) {
+ if(!isdigit(*str))
+ return false;
+ str++;
+ }
+ return true;
+}
+
+bool util_strncmpexact(const char *src, const char *ned, size_t len) {
+ return (!strncmp(src, ned, len) && !src[len]);