Skip to content

Commit 3d83ff0

Browse files
author
Kareem Zidane
authored
Merge pull request #164 from cs50/develop
A few clarifications, fixes
2 parents fe383fb + a8eb48e commit 3d83ff0

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

Diff for: Makefile

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
VERSION := 9.0.0
1+
VERSION := 9.0.1
22
MAJOR_VERSION := $(shell echo $(VERSION) | head -c 1)
33

44
# installation directory (/usr/local by default)
@@ -128,6 +128,6 @@ version:
128128
.PHONY: uninstall
129129
uninstall:
130130
rm -f $(DESTDIR)/include/cs50.h
131-
rm -rf $(DESTDIR)/src/libcs50
131+
rm -rf $(DESTDIR)/src/cs50.c
132132
rm -f $(addprefix $(DESTDIR)/lib/, $(LIB_BASE) $(LIB_MAJOR) $(LIB_VERSION))
133133
rm -f $(addprefix $(DESTDIR)/$(MANDIR)/, eprintf.3 get_*.3)

Diff for: src/cs50.c

+2-2
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ static string *strings = NULL;
7878
string get_string(va_list *args, const string format, ...)
7979
{
8080
// Check whether we have room for another string
81-
if (allocations * sizeof (string) == SIZE_MAX)
81+
if (allocations == SIZE_MAX / sizeof (string))
8282
{
8383
return NULL;
8484
}
@@ -374,7 +374,7 @@ long get_long(const string format, ...)
374374
// Try to get a long from user
375375
while (true)
376376
{
377-
// Get line of text, returning LLONG_MAX on failure
377+
// Get line of text, returning LONG_MAX on failure
378378
string line = get_string(&ap, format);
379379
if (line == NULL)
380380
{

Diff for: src/cs50.h

+3-3
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,8 @@
3636
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
3737
*/
3838

39-
#ifndef _CS50_H
40-
#define _CS50_H
39+
#ifndef CS50_H
40+
#define CS50_H
4141

4242
#include <float.h>
4343
#include <limits.h>
@@ -51,7 +51,7 @@
5151
typedef unsigned char byte;
5252

5353
/**
54-
* Our own type for strings.
54+
* Our own type for (pointers to) strings.
5555
*/
5656
typedef char *string;
5757

0 commit comments

Comments
 (0)