A search is presented for direct chargino production based on a disappearing-track signature using 20.3 fb(-1) of proton-proton collisions at root s = 8 TeV collected with the ATLAS experiment at the LHC. In anomaly-mediated supersymmetry breaking (AMSB) models, the lightest chargino is nearly mass degenerate with the lightest neutralino and its lifetime is long enough to be detected in the tracking detectors by identifying decays that result in tracks with no associated hits in the outer region of the tracking system. Some models with supersymmetry also predict charginos with a significant lifetime. This analysis attains sensitivity for charginos with a lifetime between 0.1 and 10 ns, and significantly surpasses the reach of the LEP experiments. No significant excess above the background expectation is observed for candidate tracks with large transverse momentum, and constraints on chargino properties are obtained. In the AMSB scenarios, a chargino mass below 270 GeV is excluded at 95% confidence level.