The inner ring in the tool wheel has an option to control smoothing, and it appears as a squiggly line symbol. When you tap this, it brings up a slider and preset smoothing values (customizable with a tap+hold). Setting the slider to 100% makes any stroke you draw or select snap to the shortest length between endpoints, creating a straight line. This can make it tricky to draw things like circles, so if your lines are behaving strangely or adjusting themselves without you, make sure the smoothing slider is set where you want it to be.

This particularly affects the Fill tool, which fills a positive space from start point to end point. If the smoothing is set to 100%, the stroke will disappear entirely.