Attached is a patch that gives the option in CSV Dataset Config Element to disallow recycling values once the end of the file is reached. When the end of the file is reached nulls are simply returned. This allows you to use an if controller to stop the thread, etc.
Created attachment 18277 [details] adds recycle option to csv data set
FYI, leaves the default behavior of recycling values after the final line is reached.
Code has been added to the 2.1 branch, and the documentation has been updated. The nightly build 2-1.20060519 contains the updates
This issue has been migrated to GitHub: https://github.com/apache/jmeter/issues/1721