-
- /*
- * Determine if the input is "old" syslog format or new ASL format.
- * Old format lines should start with "<", but they can just be
- * straight text. ASL input starts with a length (10 bytes)
- * followed by a space and a '['.
- */
- format = FMT_LEGACY;
- off = 0;
-
- if ((uline[0] != '<') && (len > 11))
- {
- status = sscanf(uline, "%d ", &x);
- if (status == 1)
- {
- if ((uline[10] == ' ') && (uline[11] == '['))
- {
- format = FMT_ASL;
- off = 11;
- }
- }
- }
-
- return udp_convert(format, uline+off, len-off, r);
+ m = asl_input_parse(uline, len, r, SOURCE_UDP_SOCKET);
+ process_message(m, SOURCE_UDP_SOCKET);