[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Gnash-commit] gnash libamf/sol.cpp ChangeLog
From: |
Rob Savoye |
Subject: |
[Gnash-commit] gnash libamf/sol.cpp ChangeLog |
Date: |
Tue, 22 Jan 2008 01:26:04 +0000 |
CVSROOT: /sources/gnash
Module name: gnash
Changes by: Rob Savoye <rsavoye> 08/01/22 01:26:04
Modified files:
libamf : sol.cpp
. : ChangeLog
Log message:
* libamf/sol.cpp: Swap from host to network for the magic
number,
not network to host. Fixes #22013.
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/gnash/libamf/sol.cpp?cvsroot=gnash&r1=1.16&r2=1.17
http://cvs.savannah.gnu.org/viewcvs/gnash/ChangeLog?cvsroot=gnash&r1=1.5453&r2=1.5454
Patches:
Index: libamf/sol.cpp
===================================================================
RCS file: /sources/gnash/gnash/libamf/sol.cpp,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -b -r1.16 -r1.17
--- libamf/sol.cpp 21 Jan 2008 22:55:27 -0000 1.16
+++ libamf/sol.cpp 22 Jan 2008 01:26:03 -0000 1.17
@@ -55,7 +55,8 @@
// Object Name - variable (the name of the object as an AMF encoded string)
// Padding - 4 bytes
// After this is a series of AMF objects
-const short SOL_MAGIC = 0x00bf; // this is in big-endian format already
+const short SOL_MAGIC = 0x00bf; // is in big-endian format, this is the
first
+ // two bytes. of the .sol file.
//char *SOL_FILETYPE = "TCSO";
const short SOL_BLOCK_MARK = 0x0004;
@@ -124,7 +125,7 @@
// First we add the magic number. All SOL data is in big-endian format,
// so we swap it first.
boost::uint16_t swapped = SOL_MAGIC;
-// swapped = ntohs(swapped);
+ swapped = htons(swapped);
boost::uint8_t *ptr = reinterpret_cast<boost::uint8_t *>(&swapped);
for (i=0; i<sizeof(boost::uint16_t); i++) {
_header.push_back(ptr[i]);
Index: ChangeLog
===================================================================
RCS file: /sources/gnash/gnash/ChangeLog,v
retrieving revision 1.5453
retrieving revision 1.5454
diff -u -b -r1.5453 -r1.5454
--- ChangeLog 21 Jan 2008 23:01:12 -0000 1.5453
+++ ChangeLog 22 Jan 2008 01:26:04 -0000 1.5454
@@ -1,3 +1,8 @@
+2008-01-21 Rob Savoye <address@hidden>
+
+ * libamf/sol.cpp: Swap from host to network for the magic number,
+ not network to host. Fixes #22013.
+
2008-01-21 Bastiaan Jacques <address@hidden>
* server/asobj/NetStreamGst.cpp: don't neglect to link the video