- cs = skip_to_space (cs);
-
- int intermediate = 0;
- int nof = sscanf (cs, "%d.%d.%d.%*d", major, &intermediate, minor);
-
- /* Internal versions are represented only as MAJOR.MINOR, where
- minor is usually 0.
- Public versions have 3 fields as described with the command
- above. */
- if (nof == 3)
- return true;
-
- if (nof == 2)
- {
- *minor = intermediate;
- return true;
- }
+ const char *version_str = producer + version[0].rm_so;
+ sscanf (version_str, "%d.%d", major, minor);
+ return true;