~ubuntu-branches/ubuntu/trusty/grub2/trusty

« back to all changes in this revision

Viewing changes to grub-core/lib/libgcrypt/cipher/md4.c

  • Committer: Package Import Robot
  • Author(s): Colin Watson
  • Date: 2014-01-16 15:18:04 UTC
  • mfrom: (17.6.38 experimental)
  • Revision ID: package-import@ubuntu.com-20140116151804-3foouk7fpqcq3sxx
Tags: 2.02~beta2-2
* Convert patch handling to git-dpm.
* Add bi-endian support to ELF parser (Tomohiro B Berry).
* Adjust restore_mkdevicemap.patch to mark get_kfreebsd_version as static,
  to appease "gcc -Werror=missing-prototypes".
* Cherry-pick from upstream:
  - Change grub-macbless' manual page section to 8.
* Install grub-glue-efi, grub-macbless, grub-render-label, and
  grub-syslinux2cfg.
* grub-shell: Pass -no-pad to xorriso when building floppy images.

Show diffs side-by-side

added added

removed removed

Lines of Context:
53
53
#include <string.h>
54
54
 
55
55
#include "g10lib.h"
56
 
#include "memory.h"
57
56
#include "cipher.h"
58
57
 
59
58
#include "bithelp.h"
199
198
  MD4_CONTEXT *hd = context;
200
199
 
201
200
  if( hd->count == 64 ) /* flush the buffer */
202
 
    { 
 
201
    {
203
202
      transform( hd, hd->buf );
204
203
      _gcry_burn_stack (80+6*sizeof(void*));
205
204
      hd->count = 0;
260
259
  lsb <<= 3;
261
260
  msb <<= 3;
262
261
  msb |= t >> 29;
263
 
  
 
262
 
264
263
  if( hd->count < 56 )  /* enough room */
265
264
    {
266
265
      hd->buf[hd->count++] = 0x80; /* pad */
267
266
      while( hd->count < 56 )
268
267
        hd->buf[hd->count++] = 0;  /* pad */
269
268
    }
270
 
  else /* need one extra block */ 
271
 
    { 
 
269
  else /* need one extra block */
 
270
    {
272
271
      hd->buf[hd->count++] = 0x80; /* pad character */
273
272
      while( hd->count < 64 )
274
273
        hd->buf[hd->count++] = 0;
326
325
    md4_init, md4_write, md4_final, md4_read,
327
326
    sizeof (MD4_CONTEXT)
328
327
  };
329