---
title: "CVE-2008-1685\n    | Ubuntu"
description: Ubuntu is an open source software operating system that runs from the
  desktop, to the cloud, to all your internet connected things.
url: https://ubuntu.com/security/CVE-2008-1685?format=md
keywords: index, follow
---

# CVE-2008-1685

Publication date 6 April 2008

Last updated 4 August 2025

---

Ubuntu priority

**Low**

[Why this priority?](https://ubuntu.com/security/cves/about#priority )

Toggle side navigation

## Description

gcc 4.2.0 through 4.3.0 in GNU Compiler Collection, when casts are not
used, considers the sum of a pointer and an int to be greater than or equal
to the pointer, which might lead to removal of length testing code that was
intended as a protection mechanism against integer overflow and buffer
overflow attacks, and provide no diagnostic message about this removal.
NOTE: the vendor has determined that this compiler behavior is correct
according to section 6.5.6 of the C99 standard (aka ISO/IEC 9899:1999)

[Read the notes from the security team](https://ubuntu.com/security/CVE-2008-1685?format=md#notes)

## Status

Show unmaintained releases

| Package | Ubuntu Release | Status |
| --- | --- | --- |
| gcc-4.2 | 9.10 karmic | Ignored |
| 9.04 jaunty | Ignored |
| 8.10 intrepid | Ignored |
| 8.04 LTS hardy | Ignored |
| 7.10 gutsy | Ignored end of life, was needed |
| 7.04 feisty | Not in release |
| 6.10 edgy | Not in release |
| 6.06 LTS dapper | Not in release |
| gcc-4.3 | 9.10 karmic | Ignored |
| 9.04 jaunty | Ignored |
| 8.10 intrepid | Ignored |
| 8.04 LTS hardy | Not in release |
| 7.10 gutsy | Not in release |
| 7.04 feisty | Not in release |
| 6.10 edgy | Not in release |
| 6.06 LTS dapper | Not in release |

---

* [How can I get the fixes?](https://ubuntu.com/security/cves/about#security)
* [What do statuses mean?](https://ubuntu.com/security/cves/about#statuses)

## Notes

---

### [jdstrand](https://launchpad.net/~jdstrand)

gcc-4.3 exists in main, so watch for Intrepid and later

---

### [mdeslaur](https://launchpad.net/~mdeslaur)

upstream says this isn't an issue:
http://gcc.gnu.org/ml/gcc/2008-04/msg00115.html

## References

* [MITRE](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2008-1685)
* [NVD](https://nvd.nist.gov/vuln/detail/CVE-2008-1685)
* [Launchpad](https://launchpad.net/bugs/cve/CVE-2008-1685)
* [Debian](https://security-tracker.debian.org/tracker/CVE-2008-1685)

### Other references

* <https://www.cve.org/CVERecord?id=CVE-2008-1685>
