Longevity is a typical quantitative trait which is influenced by multiple genes. Here we explore the genetic variation in longevity of Drosophila melanogaster in both mildly heat-stressed and control flies. Quantitative trait loci (QTL) analysis for longevity was performed in a single-sex environment at 25°C with and without a mild heat-stress pre-treatment, using a previously reported set of recombinant inbred lines (RIL). QTL regions for longevity in heat-stressed flies overlapped with QTL for longevity in control flies. All longevity QTL co-localized with QTL for longevity identified in previous studies using very different sets of RIL in mixed sex environments, though the genome is nearly saturated with QTL for longevity when considering all previous studies. Heat stress decreased the number of significant QTL for longevity if compared to the control environment. Our mild heat-stress pre-treatment had a beneficial effect (hormesis) more often in shorter-lived than in longer-lived RIL.