Some DWG drawings may contain curves (polylines) with selfintersecting segments (creating loops), or polylines containing duplicate vertices - superfluous repeating vertices or "backing" (zig-zag, self-retracing) segments or segment parts. Such polylines with non-standard geometry may cause different problems when processing (in 3D, for Civil objects, LISP apps, etc.), in older AutoCAD versions, even the AREA command failed on these.
To find any self-intersections and duplicate vertices, you can use the freeware utility CADstudio SelfIntersect, which can be downloaded from www.cadstudio.cz/download. Load the VLX file with APPLOAD, type the command SELFINTERSECT and select a polyline (or use "M" for multiple, or "H" for this help). The application displays any intersections (in green), duplicate vertices (in red), and zig-zag parts (retracing, touching - in yellow) with temporary marks (remove them by Redraw, [F7]/[F7]).
Duplicate start/end vertex on open polylines may be OK.
NOTE: you can also use the LISP function:
defined in this tool to check objects programatically. Returns a number of problem points or nil.