mirror of
				https://gitlab.gnome.org/GNOME/glib.git
				synced 2025-10-31 08:22:16 +01:00 
			
		
		
		
	Make 'length' parameter signed to accomodate passing negative lengths.
2008-02-27 Matthew Barnes <mbarnes@redhat.com> * glib/gchecksum.[ch] (g_checksum_update), (g_compute_checksum_for_string): Make 'length' parameter signed to accomodate passing negative lengths. (#510855) svn path=/trunk/; revision=6600
This commit is contained in:
		
				
					committed by
					
						 Matthew Barnes
						Matthew Barnes
					
				
			
			
				
	
			
			
			
						parent
						
							82046b6c97
						
					
				
				
					commit
					154ebf8e78
				
			| @@ -1,3 +1,9 @@ | |||||||
|  | 2008-02-27  Matthew Barnes  <mbarnes@redhat.com> | ||||||
|  |  | ||||||
|  | 	* glib/gchecksum.[ch] (g_checksum_update), | ||||||
|  | 	(g_compute_checksum_for_string): Make 'length' parameter | ||||||
|  | 	signed to accomodate passing negative lengths. (#510855) | ||||||
|  |  | ||||||
| 2008-02-26  Tor Lillqvist  <tml@novell.com> | 2008-02-26  Tor Lillqvist  <tml@novell.com> | ||||||
|  |  | ||||||
| 	* glib/gmain.c (g_poll): Further patch by Vlad Grecescu: Drop the | 	* glib/gmain.c (g_poll): Further patch by Vlad Grecescu: Drop the | ||||||
|   | |||||||
| @@ -1198,7 +1198,7 @@ g_checksum_free (GChecksum *checksum) | |||||||
| void | void | ||||||
| g_checksum_update (GChecksum    *checksum, | g_checksum_update (GChecksum    *checksum, | ||||||
|                    const guchar *data, |                    const guchar *data, | ||||||
|                    gsize         length) |                    gssize        length) | ||||||
| { | { | ||||||
|   g_return_if_fail (checksum != NULL); |   g_return_if_fail (checksum != NULL); | ||||||
|   g_return_if_fail (data != NULL); |   g_return_if_fail (data != NULL); | ||||||
| @@ -1402,7 +1402,7 @@ g_compute_checksum_for_data (GChecksumType  checksum_type, | |||||||
| gchar * | gchar * | ||||||
| g_compute_checksum_for_string (GChecksumType  checksum_type, | g_compute_checksum_for_string (GChecksumType  checksum_type, | ||||||
|                                const gchar   *str, |                                const gchar   *str, | ||||||
|                                gsize          length) |                                gssize         length) | ||||||
| { | { | ||||||
|   g_return_val_if_fail (IS_VALID_TYPE (checksum_type), NULL); |   g_return_val_if_fail (IS_VALID_TYPE (checksum_type), NULL); | ||||||
|   g_return_val_if_fail (str != NULL, NULL); |   g_return_val_if_fail (str != NULL, NULL); | ||||||
|   | |||||||
| @@ -54,7 +54,7 @@ GChecksum *           g_checksum_copy       (const GChecksum  *checksum); | |||||||
| void                  g_checksum_free       (GChecksum        *checksum); | void                  g_checksum_free       (GChecksum        *checksum); | ||||||
| void                  g_checksum_update     (GChecksum        *checksum, | void                  g_checksum_update     (GChecksum        *checksum, | ||||||
|                                              const guchar     *data, |                                              const guchar     *data, | ||||||
|                                              gsize             length); |                                              gssize            length); | ||||||
| G_CONST_RETURN gchar *g_checksum_get_string (GChecksum        *checksum); | G_CONST_RETURN gchar *g_checksum_get_string (GChecksum        *checksum); | ||||||
| void                  g_checksum_get_digest (GChecksum        *checksum, | void                  g_checksum_get_digest (GChecksum        *checksum, | ||||||
|                                              guint8           *buffer, |                                              guint8           *buffer, | ||||||
| @@ -65,7 +65,7 @@ gchar *g_compute_checksum_for_data   (GChecksumType  checksum_type, | |||||||
|                                       gsize          length); |                                       gsize          length); | ||||||
| gchar *g_compute_checksum_for_string (GChecksumType  checksum_type, | gchar *g_compute_checksum_for_string (GChecksumType  checksum_type, | ||||||
|                                       const gchar   *str, |                                       const gchar   *str, | ||||||
|                                       gsize          length); |                                       gssize         length); | ||||||
|  |  | ||||||
| G_END_DECLS | G_END_DECLS | ||||||
|  |  | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user