Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

libbase: add abort()

  • Loading branch information...
commit 7414dcaeed3fdb00fa4eb8b9ced32bd23b2d9615 1 parent 6f8f96b
Sébastien Bourdeauducq sbourdeauducq authored
Showing with 9 additions and 2 deletions.
  1. +2 −1  software/include/base/stdlib.h
  2. +7 −1 software/libbase/libc.c
3  software/include/base/stdlib.h
View
@@ -1,6 +1,6 @@
/*
* Milkymist SoC (Software)
- * Copyright (C) 2007, 2008, 2009 Sebastien Bourdeauducq
+ * Copyright (C) 2007, 2008, 2009, 2011 Sebastien Bourdeauducq
* Copyright (C) Linux kernel developers
*
* This program is free software: you can redistribute it and/or modify
@@ -50,6 +50,7 @@ long strtol(const char *nptr, char **endptr, int base);
float atof(const char *s);
unsigned int rand();
+void abort();
void *malloc(size_t size);
void free(void *p);
8 software/libbase/libc.c
View
@@ -1,6 +1,6 @@
/*
* Milkymist SoC (Software)
- * Copyright (C) 2007, 2008, 2009, 2010 Sebastien Bourdeauducq
+ * Copyright (C) 2007, 2008, 2009, 2010, 2011 Sebastien Bourdeauducq
* Copyright (C) Linus Torvalds and Linux kernel developers
*
* This program is free software: you can redistribute it and/or modify
@@ -569,3 +569,9 @@ unsigned int rand()
seed = 129 * seed + 907633385;
return seed;
}
+
+void abort()
+{
+ printf("Aborted.");
+ while(1);
+}
Please sign in to comment.
Something went wrong with that request. Please try again.