diff options
author | Matthias Hopf <mat@mshopf.de> | 2006-12-08 16:26:10 +0000 |
---|---|---|
committer | Matthias Hopf <mat@mshopf.de> | 2006-12-08 16:26:10 +0000 |
commit | 4169f9efdaeda8a60b5cfd464bd39b80a9dd2032 (patch) | |
tree | fc007ba74c24176b7772442ddf9433242df16ad7 /src/libsputext/demux_sputext.c | |
parent | 3321b7ae77daede398739a832e75c5dfba7de22e (diff) | |
download | xine-lib-4169f9efdaeda8a60b5cfd464bd39b80a9dd2032.tar.gz xine-lib-4169f9efdaeda8a60b5cfd464bd39b80a9dd2032.tar.bz2 |
Fix wrong length specification for strncat() calls.
Consolidated multiple strncat() calls to snprintf().
CVS patchset: 8407
CVS date: 2006/12/08 16:26:10
Diffstat (limited to 'src/libsputext/demux_sputext.c')
-rw-r--r-- | src/libsputext/demux_sputext.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/libsputext/demux_sputext.c b/src/libsputext/demux_sputext.c index d5c591212..db0b826de 100644 --- a/src/libsputext/demux_sputext.c +++ b/src/libsputext/demux_sputext.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: demux_sputext.c,v 1.49 2006/07/10 22:08:30 dgp85 Exp $ + * $Id: demux_sputext.c,v 1.50 2006/12/08 16:26:10 mshopf Exp $ * * code based on old libsputext/xine_decoder.c * @@ -915,7 +915,8 @@ static subtitle_t *sub_read_line_jacobsub(demux_sputext_t *this, subtitle_t *cur return NULL; trail_space(directive); strncat(line2, directive, - (LINE_LEN > 511) ? LINE_LEN : 511); + ((LINE_LEN > 511) ? LINE_LEN-1 : 511) + - strlen(line2)); break; } default: |